Moonworkers
HMRC Recognised Software

UK Payroll API

The UK payroll engine
your platform is missing.

Add a complete, HMRC-compliant UK payroll engine to your ERP, HR platform or workforce tool via a single REST API. Employees, pay runs, RTI submissions and statutory obligations, all handled for you.

Read the API docs
HMRC-recognised softwareRTI and auto-enrolment included99.9% uptime SLAUK GDPR compliant
  • Multiple employers and pay schedules

    Manage unlimited employer entities under a single integration. Run parallel pay schedules of any frequency, including multiple weekly or monthly schemes simultaneously.

  • Complete UK payroll engine

    PAYE, NI, directors, CIS subcontractors, zero-hours and variable workers all handled. RTI submissions fire automatically on every pay run, no manual steps.

  • HMRC document schemas included

    Payslip PDFs, P60, P45, P11D and CIS300 deduction statements all generated and served via API. No third-party document service required.

  • Statutory pay and auto-enrolment

    SMP, SSP, SPP, ShPP and SAP calculated automatically. Pension auto-enrolment assessment, contribution splits and opt-out handling built into every pay run.

Trusted by UK businesses and accountancy firms

4.7onTrustpilot
5.0onGoogle
Suzaku Consulting
Fletchers Fibre Services
Maison Puget Bakery
Holbeach Children's Club
The Barn at Berryfields
Camelot Music Festival
Wantsum Medical Group
Ergo Design
Hayachi Services
Levelup Escapes
Seamless Advisory
BuzzBoost Group
The Property Hub
Lyrici Arts
Green Core Builders
Sienna Glass
Suzaku Consulting
Fletchers Fibre Services
Maison Puget Bakery
Holbeach Children's Club
The Barn at Berryfields
Camelot Music Festival
Wantsum Medical Group
Ergo Design
Hayachi Services
Levelup Escapes
Seamless Advisory
BuzzBoost Group
The Property Hub
Lyrici Arts
Green Core Builders
Sienna Glass

Employers and Employees

Multiple entities.
One integration.

Model your entire customer base in the API. Each employer gets its own payroll, employees and document history. Onboard a new worker with a single POST, the API validates everything before it touches compliance.

  • Multiple employers, one integration

    Create and manage unlimited employer entities. Run payroll for each entity independently while keeping all data under a single API key.

  • Every UK employment type

    Employee, director, IR35 deemed employee, CIS subcontractor and agency worker, all supported. NI and tax code validation rejects bad data before it reaches HMRC.

  • Idempotent creation

    Pass your own external ID and re-POST safely. Duplicate records are never created from retry logic, making bulk onboarding safe.

POST /v1/employees/
POSThttps://api.moonworkers.co.uk/v1/employees/

Request body

{
"first_name": "Sarah",
"last_name": "Mitchell",
"ni_number": "AB123456C",
"tax_code": "1257L",
"employment_type": "employee",
"pay_frequency": "monthly",
"annual_salary": 42000,
"ni_category": "A",
"start_date": "2026-05-01"
}

Response

201 Created
{
"id": "emp_7k2mxp19",
"status": "active",
"first_name": "Sarah",
"last_name": "Mitchell",
"payroll_id": "MW-0047",
"tax_code": "1257L",
"created_at": "2026-05-04T09:31:22Z"
}
NI validated
Tax code verified
HMRC-ready
POST /v1/payruns/
POSThttps://api.moonworkers.co.uk/v1/payruns/

Request body

{
"pay_period_start": "2026-05-01",
"pay_period_end": "2026-05-31",
"pay_date": "2026-05-28",
"employees": [complex]
}

Response

201 Created
{
"id": "run_9x4wlk82",
"status": "processing",
"employee_count": 2,
"pay_date": "2026-05-28"
}

Pay run summary — run_9x4wlk82

£7,583.33

Gross

£1,204.60

PAYE

£721.14

NI

£5,657.59

Net pay

FPS submitted to HMRC · RTI ref MW-FPS-20260528

Pay schedules and Pay runs

Run payroll.
RTI fires itself.

Define as many pay schedules as your customers need, monthly, weekly, multiple of the same, all in parallel. Trigger a pay run and the API handles every calculation, every deduction and every HMRC submission.

  • Parallel pay schedules, any frequency

    Run multiple weekly, fortnightly or monthly pay schedules simultaneously, including several schedules of the same frequency within one employer, all processed independently.

  • RTI submitted automatically

    Every pay run fires a Full Payment Submission to HMRC automatically. No manual RTI step, no third-party gateway. Employer Payment Summaries are handled on the same basis.

  • PAYE, NI and pension calculated

    Tax and NI are computed per HMRC rates. Auto-enrolment pension contributions are assessed and included for eligible employees on every run.

Payslips, Documents and CIS

Every HMRC document.
One API.

Retrieve any payroll document, payslip, P60, P45, P11D, or CIS statement, as structured JSON or a ready-to-download PDF. Store them in your document management system or surface them in your own UI.

  • Payslip PDF and JSON from one endpoint

    Every payslip is available as a machine-readable JSON breakdown and a print-ready HMRC-compliant PDF, available immediately after the pay run completes.

  • P60, P45, P11D and year-end documents

    End-of-year P60s and leaver P45s are generated automatically. P11D benefit-in-kind documents and year-end submissions are handled through the same resource pattern.

  • CIS300 and subcontractor deduction statements

    Construction Industry Scheme monthly returns are filed automatically alongside PAYE. Subcontractor deduction statements are generated per payment run.

GET /v1/payslips/{id}/
GEThttps://api.moonworkers.co.uk/v1/payslips/psl_4m7qjr91/

Response

200 OK
{
"id": "psl_4m7qjr91",
"employee_id": "emp_7k2mxp19",
"pay_date": "2026-05-28",
"gross_pay": 3500,
"paye": 502.6,
"employee_ni": 301.14,
"employee_pension": 105,
"net_pay": 2591.26
}

Pay breakdown

Basic salary£3,500.00
PAYE tax−£502.60
Employee NI−£301.14
Pension (4%)−£105.00
Net pay£2,591.26
pdf_url
/payslips/psl_4m7qjr91/pdf/
POST /v1/employees/{id}/holidays/
POSThttps://api.moonworkers.co.uk/v1/employees/emp_7k2mxp19/holidays/

Request body

{
"start_date": "2026-06-09",
"end_date": "2026-06-13",
"holiday_type": "annual_leave",
"notes": "Summer holiday"
}

Response

201 Created
{
"id": "hol_2p5kxm37",
"status": "approved",
"days_requested": 5,
"annual_allowance": 28,
"days_taken_ytd": 11,
"days_remaining": 17
}

Holiday entitlement, Sarah Mitchell

2026/27 tax year
11 days taken28 days total allowance17 days remaining

Leave and Statutory Pay

Absence managed.
Payroll updated.

Create and manage all leave types through the API. Statutory entitlement is tracked automatically. SMP, SSP, SPP, ShPP and SAP are calculated and built into the next pay run without any manual intervention.

  • Annual leave with 52-week average pay

    Statutory 28-day allowance tracked per employee per tax year. Holiday pay for variable-hours workers is computed on a 52-week average basis, fully ERA-compliant.

  • All statutory leave and pay types

    SMP (Statutory Maternity Pay), SSP (Sick Pay), SPP (Paternity), ShPP (Shared Parental) and SAP (Adoption Pay) are all calculated and incorporated into the pay run automatically.

  • Approval workflow via API

    Submit, approve or reject leave requests programmatically. Build your own approval UI on top or route through an existing HR workflow, with holiday pay factored in automatically at payrun time.

Pensions and Auto-enrolment

Workplace pensions.
Zero manual steps.

Auto-enrolment is assessed on every pay run. Contributions are calculated, deducted and surfaced in payslip data automatically. Opt-outs, re-enrolments and postponements are all handled by the API.

  • Auto-enrolment assessment on every run

    Workers are assessed for eligibility at each pay run. Newly eligible employees are enrolled automatically, with confirmation returned in the pay run response.

  • Contribution splits calculated

    Employer and employee pension contributions are computed on qualifying earnings, deducted from net pay and broken down in both the payslip JSON and PDF. Rates are configurable per employer.

  • Opt-out and postponement handled

    Process opt-out requests and re-enrolment windows through the API. Postponement periods are tracked per worker and enrolment is triggered automatically when the window closes.

GET /v1/employees/{id}/pension/
GEThttps://api.moonworkers.co.uk/v1/employees/emp_7k2mxp19/pension/

Response

200 OK
{
"employee_id": "emp_7k2mxp19",
"status": "enrolled",
"scheme": "NEST",
"scheme_ref": "NEST-MW-4471",
"employer_rate": "3%",
"employee_rate": "5%",
"enrolled_at": "2026-05-01"
}

Contribution breakdown

Gross salary£3,500.00
Qualifying earnings£2980.00
Employer (3%)£89.40
Employee (5%)£149.00
Total£238.40

Auto-enrolment status

enrolled

Yes

Eligible

No

Opted out

None

Postponement

Who integrates

Built for platforms
that build for business.

Whether you are embedding payroll into an ERP, connecting a people platform, or building a bespoke payroll flow, the Moonworkers API gives you the full UK payroll engine through a single integration.

ERP vendors

ERP & accounting platforms

Add native UK payroll without building a payroll engine.

  • Embed compliant payroll directly inside your ERP module
  • RTI submissions handled by Moonworkers, zero compliance overhead
  • Map your own employee and ledger IDs to Moonworkers resources
Explore the API
HR platforms

HR & people platforms

Connect your HRIS to a compliant UK payroll backend.

  • Sync employee records from your HRIS on every change
  • Push leave approvals and trigger holiday pay automatically
  • Serve payslip PDFs directly inside your employee self-service portal
Explore the API
Workforce tools

Workforce & staffing platforms

Pay contractors, temp workers and shift staff via API.

  • Variable hours and daily-rate workers handled natively
  • CIS subcontractor payments with correct deductions
  • Run payroll for individual workers without a full payroll subscription
Explore the API
Custom builds

In-house development teams

Build a bespoke payroll flow for your organisation.

  • OpenAPI schema and ReDoc reference documentation included
  • Webhook events for every pay run, payslip and RTI status change
  • Staging environment for end-to-end integration testing
Explore the API

99.9%

Uptime SLA

<120ms

Median response time

40+

API endpoints

100%

RTI acceptance rate

Trusted by hundreds of UK businesses

Our customers say it best.

From sole traders to growing enterprises, teams across the UK rely on Moonworkers to run payroll without the headache.

JP

JC Puget

Maison Puget

The best payroll company for my business. Highly recommend.

SD

S Djakiodine

Euroaccounting

We have been using Moonworkers for quite some time and compared to other software in the market, we found it very simple to use and excellent. Moreover, the customer service is great.

SG

Shenaz Gaffar

Printberry

Moonworkers has absolutely been a lifesaver for me and my business. Moonworkers customer service is 100% there always there to help. They constantly taking on feedback to make it better. If you are looking to make life easier, then this is it !!!

JB

Joe Barber

The Barn

Fantastic onboarding process from the team. A really user friendly website and system. When I have asked for any assistance or help, the team have helped, made changes and even updated the system for my requests!

JB

James Berry

CJLS Tech

From the outset the onboarding to Moonworkers was 100% smooth, even any hints of a problem were speedily fixed and we have been running smoothly since then, we have never needed to reach out to support post onboarding, and that's a testament to its own.

SK

Suzy Kerton

Zyla Accountant

Moonworkers software is great for HR, payroll, benefits & more and it is amazing to have it all in one platform. The automation saves so much time every month and the team offer great customer support whenever you have a query. Highly recommend!

AG

Amrit Gill

Hayachi

Incredibly powerful HR and Payroll platform, we've previously been held back by our accountant on having a truly flexible workforce but no more! With Moonworkers we can hire the skills that we need with exceptional efficiency and the HR platform makes it a well-rounded tool.

RL

Row Laurence

Braid

The Moonworkers platform has been a massive help getting me set up with my first few employees and making sure I had all the right boxes ticked – the team have also been super helpful and responsive any time I had questions or there was something I didn't understand.

Ready to integrate?

UK payroll in your platform
without building the engine.

Read the full API reference, request a sandbox key, or speak to the team about a production integration. Most teams are live within a week.

Read the API docs
HMRC-recognisedOpenAPI schema includedFree sandbox, no cardUK GDPR compliant

FAQ

Frequently asked
questions.

Still have questions? Talk to us →