> For clean Markdown content of this page, append .md to this URL. For the complete documentation index, see https://buildwithfern.com/learn/llms.txt. # Base path > Configure base paths in OpenAPI with `x-fern-base-path`. Set up endpoint prefixes like /v1 for your API definitions with Fern. Use the `x-fern-base-path` extension to configure the base path prepended to every endpoint. The example below configures the `/v1` base path so the full endpoint path is `https://api.example.com/v1/users`. **`Set the base path in openapi.yml`** ```yaml title="Set the base path in openapi.yml" {1} x-fern-base-path: /v1 servers: - url: https://api.example.com paths: /users: ... ``` A plain base path applies to the whole API, so in a project with multiple OpenAPI specs only one document's value survives the merge. Enable [`respect-per-spec-base-path`](/learn/api-definitions/openapi/generators-yml-reference#settingsrespect-per-spec-base-path) to give each spec its own base path. > Configure base paths in OpenAPI with `x-fern-base-path`. Set up endpoint prefixes like /v1 for your API definitions with Fern.