# Document to Text

Use **Document URL to Text** when you want a workflow step to fetch a document from a public URL and extract its text inside Fetch Hive.

## Configuration

| Option                                                             | Required | Description                                                                                     |
| ------------------------------------------------------------------ | -------- | ----------------------------------------------------------------------------------------------- |
| Name                                                               | No       | Label for the step in the workflow canvas.                                                      |
| Document URL                                                       | Yes      | URL in **Document URL**. This field supports workflow variables through **Insert Variable**.    |
| When the step fails                                                | No       | Controls whether the workflow should **Terminate Workflow** or **Continue** if this step fails. |
| Add this step from the **Utilities** group in **Search steps...**. |          |                                                                                                 |

The **Document URL** field accepts a direct document link. The helper text in the editor calls out support for PDF, DOCX, PPTX, XLSX, and other document formats.

## Output

Click **Run** in the step header to test the step. Fetch Hive shows the extracted result in **Output** after the run completes.

Use the variable picker in a later step to insert the exact output path for your run. The base reference is:

```
{{STEP_IDENTIFIER.output}}
```

If you only need the full extracted result, reference the base output directly:

```
{{step_2.output}}
```

Use the variable picker to inspect any nested fields available for the document result in your workflow.

## Example

Add **Document URL to Text** from the **Utilities** group in **Search steps...**.

Set **Name** to something like `Read contract PDF`.

Paste the document link into **Document URL**. If the link comes from an earlier step, click **Insert Variable** and add that value instead.

Choose what should happen in **When the step fails**.

Click **Run** and review the extracted result in **Output** before passing it into a later step such as **AI Prompt**.

## Notes

* Use a directly reachable document URL. This step is designed for fetching a document from a URL, not for uploading a file from your local machine.
* The settings sheet supports common document formats including PDF, DOCX, PPTX, and XLSX.
* If a document requires authentication or a private session, make sure the URL you pass is actually accessible to the workflow step.

See also: [Creating and Editing](https://docs.fetchhive.com/workflows/creating-and-editing), [Testing and Iteration](https://docs.fetchhive.com/workflows/testing-and-iteration), and [Error Handling](https://docs.fetchhive.com/workflows/error-handling)
