Adding custom upload fields to your PrestaShop product pages is one of the most effective ways to sell personalized items. Whether you need customers to submit logo files, custom artwork, or specific document requirements, tailored file upload options streamline the ordering process.
Setting up these fields directly on your product pages improves user experience and eliminates back-and-forth communication after purchase. Here is a step-by-step guide to configuring custom upload fields in PrestaShop effortlessly.
Why PrestaShop Product Pages Need Custom Upload Fields
To add custom upload fields to PrestaShop product pages, you either install a dedicated upload-field module that hooks into the product form and order pipeline, or manually add a file input to the product template and process the upload via an override. The module route is faster and safer; the manual route offers full control but requires development and maintenance.
PrestaShop ships with native product attributes, combinations, and customisation fields, but none of them accept a file. A shopper can pick a colour, type a name for engraving, or choose a gift wrap option, yet there is no built-in way to attach artwork, a logo, a photo, or a signed PDF to that same order. That gap is why merchants start looking for custom upload fields.
Four scenarios push stores past the limits of the default product form:
- Personalisation: a customer uploads a photo for a printed mug, a pet portrait, or a phone case, and the print file has to travel with the order line.
- Print-on-demand: artwork arrives as press-ready files, often large and requiring a specific format, so the upload must be validated rather than accepted blindly.
- Document submission: tax exemption certificates, prescription scans, or company registration papers are needed before an order can be fulfilled.
- Made-to-order services: signage, embroidery, and engraving businesses need the customer's source file to quote or produce the item at all.
Standard PrestaShop fields fail here for a structural reason. Text and attribute values live in the database as short strings, so they can be validated, searched, and displayed without any file handling. A file is different: it has a size, a MIME type, a storage location, and a lifetime tied to a specific order and, in many cases, deleted after fulfilment.
Without a proper field, merchants improvise. They ask customers to email artwork after checkout, then match the email to an order reference by hand. That works until volume grows, at which point files get lost, orders stall, and the customer has no confirmation that anything was received.
The build-or-buy question comes down to how much you want to maintain. A module such as PrestaShop Add Custom Fields on Product Details Page gives you the field on the product page and the upload handling in one package, while a manual override gives you control over every line at the cost of owning upgrades forever.
Why Custom Upload Fields Matter on PrestaShop Product Pages
PrestaShop ships with a fixed product field set: name, price, reference, combinations, images, and a short description. There is nowhere in the native product editor to collect a logo, an artwork file, a signed document, or a photo from a customer. That gap forces merchants into awkward workarounds, such as asking buyers to email files after checkout or building product combinations that pretend to represent a file choice.
Custom upload fields close that gap. A print shop can collect print-ready artwork against the exact product line item. An engraving business can take a logo file and a text note in the same cart action. A signage supplier can request a floor plan before quoting. Each example turns a slow email thread into an order attribute stored with the order itself, which is what makes fulfilment faster and disputes rarer.
An upload field is not a nicer contact form; it is order data, and it should live with the order, not in an inbox.
Quick Answer
PrestaShop has no native product upload field. You add one either with a module that attaches a file input to the product page and stores the file against the order, or by writing a module yourself that registers the correct hooks, extends the product template, and handles validation, storage, and display. The module route is faster and safer; the manual route is free but breaks on upgrades.
What You'll Need
Gather the following before you start, so you are not blocked halfway through a configuration screen. The exact requirements depend on which route you take, and the module route needs less preparation than the manual build.
- Access level: an employee account with permission to install and configure modules, and for the manual route, file access to your theme folder plus database access.
- Plugin or version: a PrestaShop installation on a supported version, and for Method 1 the PrestaShop CMS Page Form | Customize CMS Pages with Custom Form/Fields module. Method 2 requires no module but does require a working knowledge of PrestaShop hooks and template structure.
- Time: the module route is a single sitting of configuration followed by one test order, while the manual route needs a development pass plus time for edge cases and testing.
- Difficulty: the module route is beginner friendly and needs no code, while the manual route is suited to a developer comfortable with PHP, templating, and database tables.
- Preparation: a full backup of your database and theme folder, plus a staging copy of the store if you plan to touch any template file.
How Do You Add Custom Upload Fields to PrestaShop Products?
Before you choose a route, decide what the customer must hand over: a file only, a file plus instructions, or a file plus a choice such as size or colour. That decision drives both the field configuration and where the file needs to be visible after the order lands.
Method 1: PrestaShop CMS Page Form Module
The module route gets you a working file upload field without touching core files, and it survives PrestaShop upgrades. A module installs through the standard Module Manager, registers itself on the right hooks, and gives you a back office screen for building the field. This is the path to take when you want custom upload fields live today and maintainable next year.
Our own pick for collecting files and structured requests on CMS pages is PrestaShop CMS Page Form: it adds custom forms, surveys, and questionnaires to CMS pages without code changes, turning a static page into a page that accepts customer input. Most stores running a product-level upload use a dedicated product field module alongside it.
Step 1: Install and Activate the Module
Installing first means every later setting has somewhere to live, because the whole configuration sits inside the module's own screen rather than the core product editor. Skipping the activation step is the most common reason a form never appears on the front office.
Navigate to Modules → Module Manager, then:
- Upload the module archive with Upload a module, or locate it in the marketplace list and select Install.
- Select Configure once the install finishes to open the module's settings screen.
- Confirm the module is enabled for the correct shop if you run a multi-store setup.
You should now see the module listed as installed and enabled, with its configuration entry available from the Modules area.
Step 2: Build the Form and Define Your Fields
The field definition stage is where the upload input is born, so plan the labels as a customer would read them, not as your warehouse names them. Open the module's form builder, create a new form, then add each field in the order the customer should complete them.
In the form builder, select Add new field, then:
- Field type: choose File so the input renders as an upload control rather than a text box.
- Field label: write the instruction the buyer sees, such as "Upload your print-ready artwork".
- Description: add short guidance on what makes a valid file.
- Required status: enable it when the request cannot be processed without a file.
- Field order: arrange fields so simple choices come before any file request.
Tip: Name the label after the deliverable, not the mechanism. "Upload your print-ready PDF" gets the right file; "Attachment" gets whatever is on the customer's desktop.
You should now see your form listed with each field in the sequence you set.
Step 3: Place the Form on a CMS Page
A form nobody can reach collects nothing, so placement matters as much as building it. Use the module's placement option to display your form on the chosen CMS page, then open that page on the front office to confirm the form renders and the fields appear in the intended order.
- Select the CMS page the form should appear on.
- Confirm the form position on the page matches where you want customers to meet it.
- Save the placement and open the page as a logged-out visitor to check the result.
Tip: If the form collects artwork or documents, link to that CMS page from the relevant product pages so buyers find it at the moment they are deciding, not after they have checked out.
You should now see the completed form visible to customers on the CMS page you selected.
Step 4: Test the Form End to End
Testing before you announce the feature catches the failures that only appear in a real submission, such as a required field being ignorable or a file never arriving. Place a live test submission rather than trusting a preview.
- Submit a valid file through the published form and confirm it is recorded.
- Submit an oversized file to confirm any restriction message appears as expected.
- Repeat from a customer account rather than the back office, since some themes alter the front office markup.
You should now see the file captured and retrievable exactly as intended.
Method 2: Manually Add a File Upload Field to a PrestaShop Product Page
The manual route is free and needs no module, but it means owning every line of code yourself. The work splits into five jobs: override a template, render the input, receive the file in a controller, attach the result to the cart and order, then surface it in the back office. Budget extra time for a working first pass and longer for edge cases.
Start by identifying the product template your theme actually renders. In classic themes, this is typically product.tpl under the theme folder, while modern themes built on Symfony use templates/catalog/product.tpl and Twig syntax. Never edit the original file: create an override so a future theme update does not erase your work.
Step 1: Create a Theme Override for the Product Template
Navigate to your theme directory, then create a copy of the product template in an override location. PrestaShop checks the child theme first and falls back to the parent, so an override placed correctly survives parent theme updates.
- Classic themes: copy product.tpl into your child theme folder, keeping the same relative path.
- Symfony-based themes: copy templates/catalog/product.tpl into the child theme's equivalent directory.
Warning: Back up your database and theme folder before touching a single file, and test on a staging copy rather than a live shop.
You should now see the module's configuration page with an option to create your first field.
Step 2: Render the File Input in the Template
The form must submit as multipart/form-data; otherwise, the browser sends only the filename, and the file itself is silently discarded. This is the single most common reason a manual upload field appears to work but saves nothing.
- enctype on the surrounding form element, set to multipart/form-data.
- input type="file" placed inside the add-to-cart form, so the file travels with the cart submission.
- name attribute on the input, a unique identifier you will read later in the controller.
- accept attribute: optional, to hint at which file extensions the browser should offer.
Also add a MAX_FILE_SIZE hidden input above the file field. It is only a hint to the browser and can be bypassed, so it never replaces server-side validation.
Tip: Store uploads outside the public folder and stream them through a controller so customers cannot enumerate or download other people's files by guessing URLs.
You should now see a file input rendered inside the add-to-cart form on the product page.
Step 3: Receive the Upload in a Front Controller
Browsers always send uploaded files through the $_FILES superglobal, never through $_POST. Hook your logic where PrestaShop processes the add-to-cart action, then move the temporary file out of PHP's temp directory before the request ends, because that temporary copy is deleted automatically when the script finishes.
- Read the entry from $_FILES using the same name you gave the input in Step 2.
- Check the reported error code and discard anything that failed to transfer.
- Validate the real MIME type with finfonot the extension the customer typed.
- Sanitise the filename and generate a random prefix to avoid collisions and tampering.
- Move the file with move_uploaded_file into a directory outside the web root, ideally under /upload/ or a protected folder, then record the new path.
You should now see the stored file with a recorded path your code can reference.
Step 4: Tie the File to the Cart and the Order
A file that vanishes at checkout is worse than no field at all. Persist the stored path against the cart, then copy that reference onto the order when the cart converts, so the link survives payment, status changes, and later refunds.
- Create a database table with columns for the cart ID, order ID, product ID, original name, stored path, and timestamp.
- Insert the row when the file is moved, keyed to the current cart.
- On order validation, copy the cart reference into the order record so the association is permanent.
- If two upload fields exist on one product, key each row by its field name to keep them apart.
On the order confirmation page and in the order confirmation email, render a link built from the stored path so the customer can verify exactly what they sent.
You should now see the file linked to the order record rather than only to the session.
Step 5: Display the File in the Back Office
Staff cannot act on a file they cannot find. Extend the order detail view in the back office so the uploaded filename and a download link sit alongside the product line, then hook into the order detail rendering to inject that block.
- Query your table using the order ID being viewed.
- Output the original filename, the upload timestamp, and a download link.
- Restrict the download to logged-in employees, since these are customer files.
If you need the same result without maintaining template overrides, controllers, and a custom table, the module route is worth comparing before you commit. A ready-made alternative such as the Prestashop Add Custom Fields on Product Details Page module handles the field and its storage, and PrestaShop Upload File covers the customer file side.
Weigh the trade-off honestly: the manual build costs nothing in licence fees but breaks when PrestaShop's template or controller layer changes, and you carry the security burden of validating every upload yourself. A custom upload field you wrote is a long-term maintenance commitment, not a one-time task.
Troubleshooting Common PrestaShop Upload Field Issues
Upload fields fail in predictable ways, and almost every failure traces back to one of five causes: permissions, PHP limits, validation rules, email configuration, or a conflicting module. Work through the checks below in order, because the first four affect a module-based field and a hand-coded one equally.
When Uploads Do Not Appear at All
If a customer completes the upload and you cannot find the file, start with the storage folder rather than the form. The module or your custom code writes uploads into a directory under your PrestaShop installation, and that folder needs write permission for the web server user.
- Confirm the target folder exists and is writable. On most hosting setups that means permissions of 755 for directories and 644 for files, though some hosts require stricter or looser values.
- Check the browser console and your server error log immediately after a failed upload. A 500 response during the POST points to a PHP error, not a form problem.
- Test with a very small file (a few kilobytes). If a tiny file succeeds and a larger one fails, the problem is a limit, not permissions.
If the file is written but never linked to the order, the field itself may not be registered against the product or order record. Re-check the field configuration from Step 2 and confirm the module is active on the correct shop in a multistore setup.
File Size Limits Rejecting Valid Uploads
PrestaShop inherits its upload ceiling from PHP, so a "file too large" rejection usually has nothing to do with the module. Two PHP directives control this, and they must be raised together.
| Directive | What it controls | Where to change it |
|---|---|---|
| upload_max_filesize | The largest single file PHP will accept | php.ini, or your hosting control panel's PHP settings |
| post_max_size | The total size of the whole submitted form | Same as above, must be larger than upload_max_filesize |
| max_file_uploads | How many files one submission can carry | Same as above, relevant for multi-file fields |
A common trap is raising only upload_max_filesize. If post_max_size stays low, larger submissions fail silently with an empty POST array, which looks exactly like a broken form.
Tip: Set post_max_size comfortably above upload_max_filesize so the rest of the form data still arrives when a customer attaches a file near the limit.
Wrong File Types Getting Through or Blocked
If customers cannot attach a PNG but a PDF works fine, your allowed-extension list is too narrow. If customers can attach a script file, the list is too permissive.
- Verify the accepted extensions are listed explicitly, for example jpg, png, pdf and ai for artwork, rather than relying on a wildcard.
- Remember that PrestaShop validates by file extension, not by MIME type. Renaming a file changes what the validator sees, so keep the extension list tight.
- Test each allowed type once from a real customer account, not just from the back office, since some themes alter the form markup.
Attachments Missing From Order Emails
Uploaded files are stored on the server, and email clients cannot read your server's filesystem directly. The confirmation email therefore needs either an attachment or a secure link, and both can fail.
- Check whether the notification template actually references the uploaded file. Many default templates simply do not include upload data.
- If the email attaches the file, confirm your mail configuration allows attachments of that size. Hosts often cap outgoing attachment size well below the upload limit.
- If the email links to the file, test the link while logged out. A link that only works for an authenticated admin is useless to the customer.
Confirmed order emails are also a good place to reassure buyers, and the same principle applies to other custom fields you add, such as those covered in PrestaShop Custom Checkout Fields.
Module Conflicts Breaking the Field
If the upload field works on one product but vanishes on another, or stops working after installing something new, suspect a conflicting module or a theme override.
- Temporarily switch to a default theme and retest. If the field returns, a template override in your theme is stripping the form.
- Disable recently installed modules one at a time, clearing the cache after each change, until the field reappears.
- Clear the PrestaShop cache after every module change. Stale cached templates are a frequent cause of a field that "disappeared" without any code change.
Once the conflict is isolated, reapply your theme customisations on top of the working configuration rather than debugging both at once.
Conclusion
You now have a working path from a product page to a file in your fulfilment queue, either by configuring a module that renders forms on CMS pages or by building your own with PrestaShop hooks.