The Sage Payroll File
How TempClock builds the Sage payroll file: hours and rates per worker per payment, from approved hours only, with your own payment references, ready for Sage 50 Payroll's data import.
Last checked against the product:
Overview
Payroll goes to Sage by file.
Before you start
- Agency console: the Payroll preset, an Admin or a super admin. Exporting needs Export payroll (CSV, Sage, Xero). Without it you can preview but not export.
- Client dashboard: an Admin. The file layout and payment references are set by the agency, so ask the agency to change them.
- The Sage settings below saved once by an agency Admin.
TempClock prices every shift with one rules engine and writes the Sage file from those figures: for each worker, one line per Sage payment (Basic, Overtime, Weekend, Sunday, Bank holiday, Night and Guarantee, each with your payment reference), with hours and rate. Only approved shifts are ever included.
The usual way to produce it is step 4 of Closing the Pay Week, which exports from the frozen figures of a locked week. The Sage export page produces the same file for any period and keeps a history of every export.
Sage does not offer an API for UK payroll, so payroll always goes by file. Client invoices are different: they can be sent to Sage Accounting through its API. See Sending Invoices to Sage Accounting.
Set Up Once
Match the file to your Sage company. Agency console only.
Agency console: Setup > Settings, then the Sage payroll export section. This is not in the client dashboard.
Choose the product and references
Set the Sage product, the Employee reference (the worker's badge or payroll number, or the TempClock worker number: it must match the employee reference in Sage), the Name format and the Date format.
Choose department and cost centre
Pick where Department and Cost centre come from: the site's Sage department, the cost code, the client or the site. They are taken from the site each shift was worked at, not the worker's home client.
Enter the payment reference for each element
Under Payment reference for each pay element, type the Sage payment's reference number (Sage 50 Payroll) or the pay element name (Sage cloud) exactly as it is set up in Sage. For Sage 50 Payroll the names shown at first (Basic, Overtime and so on) are placeholders: Sage's template guide defines Payment Reference as the reference number of the payment. Leave Sunday blank to pay Sundays under Weekend, and Guarantee blank to pay guaranteed-hours top-ups under Basic. Save the settings page.
Export the File
From Close week, or from the Sage export page.
Agency console: Reports > Sage export. Client dashboard: Time & Pay > Sage export.
Pick the period, client and layout
Set From and To. In the agency console choose the Client, or All clients. Choose the Layout and click Preview.
Check the preview
The preview shows Workers, Paid hours, Gross pay and File lines, then the exact lines the file will hold. A box above says how many shifts are in the file and how many were left out and why (for example waiting for approval or rejected by the client).
Export and download
Click Export and download. The button shows how many approved shifts are in the file. The file is recorded as an export batch and kept.
Tick Draft run: to include unapproved shifts in the preview while you check figures. While it is ticked the page says "Turn off the draft run to export." A final export never includes unapproved shifts.
Exporting Again
A second file asks for a reason.
If the period or the same shifts were exported before, a red box says Already exported to Sage, how many times and when, and warns that exporting again could pay them twice. Type a Reason for exporting again (at least 5 characters, for example "first file was rejected by Sage") before Export and download works. The reason is kept with the batch.
Layouts
Pick the one that matches your payroll.
| Layout | What it contains |
|---|---|
| Sage 50 Payroll | Employee Reference, Payment Reference, Hours, Rate: Sage's payment hours and rates import. One line per worker per payment reference. |
| Sage 50 Payroll: checking copy | Employee Reference, Surname, Forename, Payment Reference, Payment Name, Hours, Rate, Amount, Department, Cost Centre, Period Start, Period End. For checking; not imported. |
| Sage Payroll (cloud) | Employee ID, Employee Name, Pay Element, Units, Rate, Amount, Cost Centre, Department, Period Start, Period End. A list to enter by hand: Sage documents no import of pay values for its UK cloud payroll. |
| Generic payroll CSV | The same lines with the element name and payment reference, plus a shift count, for other payroll systems. |
| Detailed | One row per shift with clock times, pay and charge, for checking. |
| Legacy Sage 50 and Legacy Sage cloud | The older one-line-per-worker files, kept for customers already importing them. |
Sage 50 Payroll imports hours and rates, not amounts, and pays Hours x Rate. So TempClock sets each rate so that Hours x Rate equals the pay the engine worked out, to the penny; that can mean a rate with 4 decimal places. Where two rates fall under one payment reference (for example Sunday paid under Weekend), they are joined into one line at a blended rate, because Sage keeps one set of hours and rate per payment. The preview lists any such lines and shows what Sage will pay.
Import into Sage
Using Sage's own import.
Sage 50 Payroll: in Sage go to File, Data Import, Import Sage Payroll Data, choose Employee Payments (Hours and Rates) and browse to the file (close it in Excel first). Payment references must be letters, numbers and spaces only: Sage refuses pay element names with other characters, and TempClock will not export them.
Before the first import, check Sage: each payment you send must already be assigned to each employee, as a fixed (non-global) hourly payment. Sage\'s import updates the hours and rate of a payment the employee already has; it does not add one, and global payments do not import. Assign every mapped payment to every temporary worker, and to each new starter before their first import. Sage\'s Employee Payments template can do this in bulk.
Sage Payroll (cloud): Sage does not document an import of pay values for its UK cloud payroll, so the cloud layout is a list for your payroll team to enter. If your Sage Payroll account has an import, show us and we will match it.
Export History
Every file is kept.
The Export history table on the Sage export page lists every file exported for the period: batch number, when, the period, the layout, how many shifts and the pay total, with the reason if it was an export again. Click Download again to get exactly what was sent.
Test Import First
Before the first live payroll.
The Sage 50 Payroll file follows Sage's published import rules, but it has not been imported into your company yet when you start. During setup we export a synthetic week, import it into a copy of your Sage company with your payroll person, check the template headings, the payment numbers, that every worker has each payment assigned, and the 4-decimal rates, and fix any differences before the first live run.
Troubleshooting
Common messages.
| What you see | Why | What to do |
|---|---|---|
| "You can preview but not export. Ask an admin for the export permission." | Your user lacks Export payroll (CSV, Sage, Xero). | Ask a super admin for the Payroll preset. |
| "No approved shifts to export for this period." | Nothing in the period is approved. | Approve on Timesheets or Close week, then preview again. |
| The button reads "Export and download (0 approved shifts)" and is greyed out | No approved shifts in the period. | Approve them on Close week or Timesheets, then preview again. |
| "Turn off the draft run to export." | The draft run is ticked. | Untick Draft run: and click Preview. |
| Sage rejects a line for a payment the employee does not have | The payment is not assigned to that employee in Sage, it is a global payment, or the payment reference is a name, not the Sage payment number. | Assign the payment to the employee in Sage as a fixed hourly payment, or correct the number in Setup > Settings, Sage, then import again. |
| A worker is missing | See the left-out list in the preview. | See Export and Payroll Issues. |
Know who turned up, and pay every hour right.
Face-verified clock-ins, live geofencing and payroll-ready timesheets in one system. Tell us how your shifts run and we will show you how it fits.
Hosted in the EU · Your largest site live first, with us alongside · No app needed to clock in