Subscriber Import & Export
When you migrate from another billing system or onboard a batch of customers at once, you don’t want to type each subscriber into the Subscribers page by hand. The Import page lets you upload a spreadsheet and create hundreds of subscribers in one pass, with a row-by-row report telling you exactly which rows succeeded and which failed (and why).
ProxPanel ships two import paths that look similar but are wired to different endpoints with different permissions:
| Path | Endpoint | Permission | Used by |
|---|---|---|---|
| Excel import (the UI page) | POST /subscribers/import-excel | AdminOnly | The Import Subscribers page (/subscribers/import) |
| CSV import | POST /subscribers/bulk-import | subscribers.create | Programmatic / older multipart CSV upload |
The page you see in the panel uses the Excel path. The CSV path is a separate endpoint that accepts a raw multipart CSV file — useful for scripting, and reachable by any user (including resellers) with subscribers.create.
How to get here
Section titled “How to get here”Sidebar → Subscribers → Import button, or go directly to /subscribers/import. The page route itself is gated by subscribers.create, but the Excel import call it makes is AdminOnly — a reseller can open the page but the import will be rejected with Only admin can bulk import. For resellers, use the CSV bulk-import endpoint instead.
Excel import — step by step
Section titled “Excel import — step by step”The page walks you through three steps.
- Download the sample file. Click Download Sample Excel to get
import_subscribers_sample.xlsx. It shows the expected layout: row 1 is the header, row 2 is a description/hint row, and data starts at row 3. - Upload your file. Click Choose File and pick a
.xlsxor.xls. Parsing happens entirely in your browser — the spreadsheet is read with thexlsxlibrary, never uploaded as a binary. The page auto-detects whether row 2 is a description row (it looks for words like “required”, “optional”, “format”, “example”) and skips it; otherwise data is read from row 2. - Review & import. A preview table shows the first 100 parsed rows. Rows missing a required field, or whose Service name doesn’t match an existing service, are highlighted red. Click Import All to send the parsed data to the server.
You can optionally pick a Default NAS before importing. That NAS ID is attached to every created subscriber.
Column mapping
Section titled “Column mapping”Column headers are matched case-insensitively, with spaces and * stripped. Each field accepts several aliases, so a header of User, username, or Username * all map to the same field:
| Field | Accepted header aliases | Required |
|---|---|---|
| Username | username, user | Yes |
| Password | password, pass | Yes |
| Service | service, plan, package | Yes (must match an existing service name) |
| Full name | full_name, name, fullname | No |
| Expiry | expiry, expiry_date, expires, exp | No |
| Phone | phone, mobile, tel | No |
| Address | address, addr | No |
| Region | region, area | No |
| Building | building, bldg | No |
| Nationality | nationality, nation | No |
| Country | country | No |
| MAC address | mac_address, mac | No |
| Note | note, notes, comment | No |
| Reseller | reseller | No (matched by reseller name) |
| Blocked | blocked, block, status | No |
What the server does per row
Section titled “What the server does per row”For each row the import-excel handler:
- Validates that Username, Password, and Service are all present — otherwise the row fails.
- Looks up the Service by name (case-insensitive). Unknown service name fails the row with
Service '<name>' not found. - Checks the username isn’t already taken — duplicates fail with
Username already exists. - Parses the Expiry. It tries
YYYY-MM-DDfirst, thenDD/MM/YYYY, thenMM/DD/YYYY. An unparseable date fails the row. An empty expiry defaults to 30 days from now. - Resolves the Reseller by name if provided (unknown reseller names are silently ignored — the subscriber is created with no reseller).
- Sets status to Active, unless the Blocked column is
1,true, oryes, in which case status is Stopped. - Creates the subscriber, then writes RADIUS rows:
radcheck:Cleartext-Password,Expiration,Simultaneous-Use := 1.radreply:Mikrotik-Rate-Limitfrom the service’s speed strings, andFramed-Poolif the service has a pool name.
The subscriber’s MAC is upper-cased and MAC-binding (SaveMAC) is turned on automatically when a MAC is supplied.
The results report
Section titled “The results report”After import, a results table lists every row with a green Success or red Failed badge and a message (the same per-row reasons listed above). The group header summarises N success, M failed. From there you can click Import More to reset the form, or Go to Subscribers to see the new accounts.
CSV import (bulk-import endpoint)
Section titled “CSV import (bulk-import endpoint)”The bulk-import endpoint takes a multipart-uploaded CSV file plus a service_id form field, and is gated by subscribers.create rather than AdminOnly — so resellers can use it. It behaves slightly differently from the Excel path:
- All imported subscribers get the single service passed in
service_id(the CSV has no per-row Service column). - Recognised CSV columns:
username/user,password/pass,full_name/fullname/name,email,phone/mobile,address. Headers are matched case-insensitively. - Only Username is required. If Password is blank, the password defaults to the username.
- Expiry is computed from the service’s own expiry value/unit (not read from the file).
- A reseller’s imports are owned by that reseller; an admin’s default to reseller ID 1.
- Like the Excel path it skips duplicate usernames and writes the same
radcheck/radreplyrows.
Both endpoints write a single audit-log entry summarising the import (Bulk imported N subscribers (M failed)).
Export
Section titled “Export”There is no subscriber-export endpoint in ProxPanel today. The pages that do export to CSV are Sessions, Audit Log, and Reports — none of which dumps the subscriber table itself. To extract the full subscriber list, query the subscribers table directly, or use the per-page CSV exports above for the data they cover.
Permissions
Section titled “Permissions”| Permission / role | Effect |
|---|---|
subscribers.create | Loads the /subscribers/import page; required for the CSV bulk-import endpoint. |
| Admin role | Required for the Excel import-excel endpoint — resellers are rejected even with subscribers.create. |
Related pages
Section titled “Related pages”- Subscribers — where imported accounts land; the Import button lives here.
- Services — the Service column /
service_idmust match a service name defined here. - Resellers — the Reseller column is matched against reseller names.
- Backups — the recommended path for full server-to-server subscriber migration.
- Bulk Operations — bulk actions (renew, reset FUP, disconnect) on subscribers that already exist.