ERPNext

ERPNext Payroll and HR Setup Guide: Step by Step

How to set up HR and payroll in ERPNext the right way: employees, holidays, leave, shifts and attendance, salary components, structures and the monthly payroll run.

Payroll is where an ERP earns trust fast, or loses it. If one salary slip is wrong, every employee hears about it. ERPNext handles HR and payroll through Frappe HR, the official HR app that installs next to ERPNext and shares the same employees, companies and accounts. Here is the order we follow when we set it up, and the settings that matter most.

Step 1: Company basics and employees

Before any salary maths, the foundations must be clean:

  • Departments, designations, branches and employee grades that match how you actually run the business. Payroll can later be filtered by these.
  • Employee records with joining date, company, department, reports-to and bank details. Import them with the Data Import tool from a spreadsheet instead of typing them one by one.
  • Holiday List for the year, with weekly offs and public holidays. Payroll and leave both read from it, so set it on the company or on each employee.

Step 2: Leave types and leave policies

Create a Leave Type for each kind of leave you give, such as annual, sick and casual, and decide whether each one is paid, can be carried forward or can be encashed. Then group them into a Leave Policy and assign it to employees, for example by grade. ERPNext creates the leave allocations from the policy, and earned leave can build up month by month.

Employees apply for leave, the leave approver set on the department or employee approves it, and the balance updates by itself. Unpaid leave flows into payroll as fewer payment days.

Step 3: Shifts and attendance

Decide early whether salary depends on leave records only, or on attendance. This is the Payroll Based On setting in Payroll Settings, with two options: Leave or Attendance.

  • Shift Type holds start and end time, grace periods for late entry and early exit, and the working hours below which a day counts as half day or absent.
  • Employee Checkin records come from the Frappe HR mobile app or from a biometric device connected through the API.
  • With auto attendance enabled on the shift type, ERPNext marks attendance from the check-ins on a schedule, including late entry and early exit flags.

If you do not use devices, HR can mark attendance in bulk with the Employee Attendance Tool, and employees can raise an Attendance Request for missed punches.

Step 4: Salary components

A Salary Component is one line on the payslip. Each is either an Earning or a Deduction, and has its own accounting account per company. Useful options on each component:

  • Formula or fixed amount, for example house rent as a percentage of basic.
  • Depends on Payment Days, so the amount reduces for unpaid leave or absence.
  • Is Tax Applicable, to include it in taxable salary.
  • Statistical component, for values used in formulas but not paid.
  • Round to the nearest integer and remove if zero valued to keep payslips tidy.

Step 5: Salary structures and assignments

A Salary Structure combines components into a template, such as Staff Monthly or Workers Monthly, with the payroll frequency and formulas. Formulas use the employee's base, so one structure can serve many employees.

A Salary Structure Assignment links an employee to a structure from a given date, with their base and variable pay, income tax slab and payroll payable account. When someone gets a raise, you create a new assignment from the new date instead of editing the old one, so history stays correct.

When you go live mid-year, the assignment also has fields for taxable earnings and tax deducted till date, so tax on the remaining months is calculated correctly.

Step 6: Income tax

ERPNext calculates tax from an Income Tax Slab for the Payroll Period. You enter the slabs, rates and any exemptions yourself, so they must match the current law in your country. Always take the slabs from the official tax authority, for example the FBR in Pakistan, and update them when the finance act changes. We test the calculation against a few real salaries before go live.

Step 7: Running payroll each month

  1. Create a Payroll Entry for the company, period and frequency. Filter by branch, department or designation if you pay groups separately.
  2. Fetch the employees and create the salary slips in one click.
  3. Review the slips. Use Additional Salary for one-off bonuses, arrears or deductions instead of editing the structure.
  4. Submit the slips. ERPNext books the payroll accrual entry to the payable account, by cost center if you set it.
  5. Make the bank entry to record the salary payment, and email password-protected payslips to employees if you enable it in Payroll Settings.

Beyond payroll

Frappe HR also covers recruitment and job offers, onboarding and separation, expense claims and employee advances, appraisals and goals, training, shift requests and full and final settlement. You do not need all of it on day one. Most companies start with employees, leave, attendance and payroll, then add the rest.

Common mistakes

  • Changing a salary structure that is already used in submitted slips, instead of creating a new one or a new assignment
  • Choosing Attendance-based payroll without reliable check-in data
  • No holiday list on employees, so working days come out wrong
  • Using last year's tax slabs after the budget changes them
  • Running the first live payroll without a parallel run against the old system

Get it right the first month

We run a parallel payroll with your old system before we switch, so the first live month has no surprises. See our ERPNext implementation service and training for HR teams, or book a free 30-minute ERP check.

Planning an ERPNext project?

Talk to an ERPNext consultant. We will review your requirements and send a fixed-price proposal.

Book a discovery call

Ready to run your business on one connected ERP?

Book a free 30-minute discovery call. We will map your processes, answer your questions and send a fixed-price proposal, with no obligation.