> For the complete documentation index, see [llms.txt](https://help.form.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.form.io/form-building/pdf-forms/dynamic-pdf-translation/testing-and-troubleshooting-pdf-translation.md). Agents can also search and read this documentation through its [MCP server](https://help.form.io/~gitbook/mcp).

# Testing and Troubleshooting PDF Translation

Use this topic to check a dynamic PDF Translation setup and resolve common issues. The steps apply to both Hosted File and Resource-based PDF Translation unless noted.

### Testing a Translation <a href="#testing-a-translation" id="testing-a-translation"></a>

1. Confirm the form's **PDF Translation Method** and its settings are saved.
2. Submit the form, or open an existing submission.
3. Download the submission as a PDF.
4. Add the `language` parameter to the download URL with a language code from your translations, then reload. For example:

```
https://yourproject.form.io/yourform/submission/[SUBMISSION_ID]/download?language=es
```

If the download URL already contains a query string, such as `?token=`, add the parameter with `&` instead:

```
https://yourproject.form.io/yourform/submission/[SUBMISSION_ID]/download?token=TOKEN&language=es
```

5. Check that the form text is translated. Only text that exactly matches a translation key is translated.

To test the language saved with a submission, submit the form while it's rendered in a specific language, then download the PDF without the `language` parameter. The PDF should use the same language.

#### Method-Specific Checks <a href="#method-specific-checks" id="method-specific-checks"></a>

**URL-based:**

* Open the Translations URL in a browser and confirm it returns valid JSON with the language codes you expect.
* To test a different file without changing the form settings, add the `translationsUrl` query parameter to the download URL.

**Resource-based:**

* Open the Language resource and confirm it has a submission for the language code you're testing.
* Confirm the value in **Language Code** matches the `language` parameter exactly, for example `es`, not `Español`.

### Troubleshooting <a href="#troubleshooting" id="troubleshooting"></a>

#### All Methods <a href="#all-methods" id="all-methods"></a>

| Symptom                                 | Likely cause                                                        | Resolution                                                                                                                            |
| --------------------------------------- | ------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- |
| PDF is in the original language         | No language was selected, or the translation settings weren't saved | Add `language` to the download URL, or confirm the submission was made in a translated form. Check that the form settings were saved. |
| Some text is translated, but not all    | The untranslated text doesn't exactly match a translation key       | Compare the keys with the form text, including capitalization, spacing, and punctuation.                                              |
| Submitted values aren't translated      | Submission data is out of scope                                     | This is expected. Only form-defined text is translated.                                                                               |
| PDF is in the wrong language            | The submission's saved language is being used                       | Add `language` to the download URL to override the saved language.                                                                    |
| Translations come from the wrong source | **PDF Translation Method** is set to the other method               | Check **PDF Translation Method** in the form's PDF Settings and save.                                                                 |

#### Hosted File PDF Translation <a href="#url-based-pdf-translation" id="url-based-pdf-translation"></a>

| Symptom                                               | Likely cause                                                                   | Resolution                                                                                           |
| ----------------------------------------------------- | ------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------- |
| PDF is in the original language for every language    | The Translations URL isn't saved, or the endpoint can't be reached             | Check the form's **Translations URL** (or the global setting) and confirm the endpoint is reachable. |
| PDF is in the original language for one language only | The language code isn't in the translations file                               | Add the language code as a top-level key in the file, or correct the code in the download URL.       |
| PDF download fails or returns an error                | The endpoint is unavailable or returns invalid content                         | Confirm the endpoint returns valid JSON with a `Content-Type` of `application/json`.                 |
| The global Translations URL is ignored                | The form has its own Translations URL, or the API Server is earlier than 9.8.4 | Clear the form's **Translations URL** to use the global setting, or upgrade the API Server.          |

#### Resource-based PDF Translation <a href="#resource-based-pdf-translation" id="resource-based-pdf-translation"></a>

| Symptom                                                                                  | Likely cause                                                  | Resolution                                                                                                                               |
| ---------------------------------------------------------------------------------------- | ------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| PDF is in the original language for every language                                       | No resource is selected, or the wrong components are selected | Check the form's PDF Settings. Confirm that **Language Code Component** and **Translation Map Component** point to the right components. |
| PDF is in the original language for one language only                                    | The resource has no submission for that language code         | Create a submission for the language, or check that the code in the download URL matches the value saved in the resource.                |
| A component isn't listed in **Language Code Component** or **Translation Map Component** | The component is nested inside a layout component             | Move the component to the top level of the Language resource.                                                                            |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.form.io/form-building/pdf-forms/dynamic-pdf-translation/testing-and-troubleshooting-pdf-translation.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
