---
title: "typolink"
manual: "TypoScript Explained"
version: "main"
permalink: "https://docs.typo3.org/permalink/t3tsref:typolink@main"
source: "Functions/Typolink.rst"
rendered: "2026-09-19T06:55:14+00:00"
---

# typolink {#typolink}

Wraps the incoming value in a link with an HTML 'a' tag.

If you do not want to have the HTML 'a' tag around the link, then you
must set the property by `returnLast = url` or
`$lconf['returnLast'] = 'url'`.

> [!WARNING]
> **Attention**
>
> If typolink is used from `parseFunc` the `$cObj->parameters` array is
> loaded with the lowercase link parameters!

-   [Properties](https://docs.typo3.org/permalink/t3tsref:properties@main)
-   [Resource references](https://docs.typo3.org/permalink/t3tsref:resource-references@main)
-   [Handler syntax](https://docs.typo3.org/permalink/t3tsref:handler-syntax@main)
-   [Examples](https://docs.typo3.org/permalink/t3tsref:examples@main)
-   [Using link handlers](https://docs.typo3.org/permalink/t3tsref:using-link-handlers@main)

## Properties {#typolink-properties}

### extTarget {#typolink-exttarget}

-   **extTarget**

    -   *Type:* string / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)
    -   *Default:* "" (no target set)

    Target used for external links

### fileTarget {#typolink-filetarget}

-   **fileTarget**

    -   *Type:* string / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    Target used for file links

### language {#typolink-language}

-   **language**

    -   *Type:* [integer](https://docs.typo3.org/permalink/t3tsref:data-type-integer@main)

    Language uid for link target

    Omitting the parameter `language` will use the current language.

    **Example**

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    page.10 = TEXT
    page.10.value = Link to the page with the ID 23 in the current language
    page.10.typolink.parameter = 23

    page.20 = TEXT
    page.20.value = Link to the page with the ID 23 in the language 3
    page.20.typolink.parameter = 23
    page.20.typolink.language = 3

    ```

### target {#typolink-target}

-   **target**

    -   *Type:* string / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    Target used for internal links

### no_cache {#typolink-no-cache}

-   **no_cache**

    -   *Type:* [boolean](https://docs.typo3.org/permalink/t3tsref:data-type-boolean@main) / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    Adds `&no_cache=1` to the link

### additionalParams {#typolink-additionalparams}

-   **additionalParams**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main) / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    This is parameters that are added to the end of the URL. This must be
    code ready to insert after the last parameter.

    **Example**

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    page.10.typolink.additionalParams = '&print=1'
    page.20.typolink.additionalParams = '&sword_list[]=word1&sword_list[]=word2'
    ```

    **Applications**

    This is very useful – for example – when linking to pages from a
    search result. The search words are stored in the register-key
    SWORD_PARAMS and can be insert directly like this:

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    page.20.typolink.additionalParams.data = register:SWORD_PARAMS
    ```

    > [!NOTE]
    > additionalParams are only considered for internal links.

### addQueryString {#typolink-addquerystring}

-   **addQueryString**

    -   *Type:* [boolean](https://docs.typo3.org/permalink/t3tsref:data-type-boolean@main) / [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)

    Add the current query string to the start of the link.

    > [!NOTE]
    > This option does not check for any duplicate parameters. This is not a
    > problem: Only the last parameter of the same name will be applied.

    Possible values:

    -   **`0`**

        No query parameters are added.

    -   **`1`**

        Only query parameters resolved by
        [route enhancers](https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/Routing/EnhancementsAspects/Index.html#routing-advanced-routing-configuration-enhancers)
        are added, any other query arguments are rejected. This way, additional
        query arguments are never added by default. This is the recommended
        behaviour.

    `untrusted`

    > Any given query parameters of the current request are added.

    **Example**

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    # Pass resolved query parameters to the link
    typolink.addQueryString = 1

    # Pass all query parameters to the link
    typolink.addQueryString = untrusted

    ```

#### addQueryString.exclude {#typolink-addquerystring-exclude}

-   **addQueryString.exclude**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)

    List of query arguments to exclude from the link. Typical examples are
    `L` or `cHash`.

    > [!WARNING]
    > **Attention**
    >
    > This property should not be used for cached contents without a valid
    > cHash. Otherwise the page is cached for the first set of parameters
    > and subsequently taken from the cache no matter what parameters
    > are given. Additionally the security risk of cache poisoning has to
    > be considered.

    **Example**

    ```typoscript
    # Remove parameter "gclid" from query string
    typolink.addQueryString.exclude = gclid
    ```

### wrap {#typolink-wrap}

-   **wrap**

    -   *Type:* [Wrap](https://docs.typo3.org/permalink/t3tsref:data-type-wrap@main) / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    Wraps the links.

### ATagBeforeWrap {#typolink-atagbeforewrap}

-   **ATagBeforeWrap**

    -   *Type:* [boolean](https://docs.typo3.org/permalink/t3tsref:data-type-boolean@main)
    -   *Default:* 0

    If set, the link is first wrapped with `wrap` and then the
    \<A>-tag.

### parameter {#typolink-parameter}

-   **parameter**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main) / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    This is the main data that is used for creating the link. It can be
    the id of a page, the URL of some external page, an email address or
    a reference to a file on the server. On top of this there can be
    additional information for specifying a target, a class and a title.
    Below are a few examples followed by full explanations.

    **Examples**

    1.  Most simple. Will create a link to page 51 (if this is not default language,
        the correct target language will be resolved from the parameter):

        **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

        ```typoscript
        page.10.typolink.parameter = t3://page?uid=51
        ```
    1.  A full example. A link to the *current* page that will open in a new window.
        The link will have a class attribute with value "specialLink" and a
        title attribute reading "Very important information":

        **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

        ```typoscript
        page.10.typolink.parameter = t3://page?uid=current _blank specialLink "Very important information"
        ```

        which is converted to a link like this:

        **Example output**

        ```html
        <a href="?id=51" target="_blank" class="specialLink" title="Very important information">
        ```
    1.  An external link with a class attribute. Note the dash (-) that
        replaces the second value (the target). This makes it possible to
        define a class (third value) without having to define a target:

        **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

        ```typoscript
        page.10.typolink.parameter = https://example.com/ - specialLink
        ```
    1.  A mailto link with a title attribute (but no target and no class):

        **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

        ```typoscript
        page.10.typolink.parameter = mailto:info@example.org - - "Send a mail to main TYPO3 contact"
        ```

    As you can see from the examples, each significant part of the
    parameter string is separated by a space. Values that can themselves
    contain spaces must be enclosed in double quotes. Each of these values
    are described in more detail below.

    Link targets that are external or contain `_blank` will be added
    `rel="noreferrer"` automatically.

    **Resource reference**

    1.  The link

        The first value is the destination of the link. It may start with:

        -   `t3://`: internal TYPO3 resource references.
            See [Resource references](https://docs.typo3.org/permalink/t3tsref:resource-references@main) for an in depth explanation on the
            syntax of these references.
        -   `http(s)://`: regular external links
        -   `mailto:info@example.org`: regular mailto links

        It's also possible to direct the typolink to use a custom function (a
        "link handler") to build the link. This is described in more detail
        below.
    1.  Target or popup settings

        Targets are normally as described above (extTarget, fileTarget,
        target). But it is possible to override them by explicitly defining
        a target in the parameter property. It's possible to use a dash (-)
        to skip this value when one wants to define a third or fourth
        value, but no target.

        Instead of a target, this second value can be used to define the
        parameters of a JavaScript popup window into which the link will be
        opened (using window.open). The height and width of the window can be
        defined, as well as additional parameters to be passed to the
        JavaScript function. Also see property "Jswindow".

        **Examples**

        Open page 51 in a popup window measuring 400 by 300 pixels:

        **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

        ```typoscript
        typolink.parameter = 51 400x300
        ```

        Open page 51 in a popup window measuring 400 by 300 pixels. Do
        not make the window resizable and show the location bar:

        **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

        ```typoscript
        typolink.parameter = 51 400x300:resizable=0,location=1
        ```
    1.  Class

        The third value can be used to define a class name for the link tag.
        This class is inserted in the tag before any other value from the
        "ATagParams" property. Beware of conflicting class attributes. It's
        possible to use a dash (-) to skip this value when one wants to define
        a fourth value, but no class (see examples above).
    1.  Title

        The standard way of defining the title attribute of the link would
        be to use the `title` property or even the `ATagParams`
        property. However it can also be set in this fourth value, in which
        case it will override the other settings. Note that the title
        should be wrapped in double quotes (") if it contains blanks.

        > [!WARNING]
        > **Attention**
        >
        > When used from `parseFunc`, the value should not
        > be defined explicitly, but imported like this:
        >
        > **EXT:site_package/Configuration/Sets/Main/setup.typoscript**
        >
        > ```typoscript
        > typolink.parameter.data = parameters : allParams
        > ```

### forceAbsoluteUrl {#typolink-forceabsoluteurl}

-   **forceAbsoluteUrl**

    -   *Type:* [boolean](https://docs.typo3.org/permalink/t3tsref:data-type-boolean@main)
    -   *Default:* `false`

    Forces links to internal pages to be absolute, thus having a proper
    URL scheme and domain prepended.

    Additional sub-property: [forceAbsoluteUrl.scheme](https://docs.typo3.org/permalink/t3tsref:typolink-forceabsoluteurl-scheme@main)

> [!NOTE]
> If the option [config.forceAbsoluteUrls](https://docs.typo3.org/permalink/t3tsref:setup-config-forceabsoluteurls@main)
> is enabled, [forceAbsoluteUrl.scheme](https://docs.typo3.org/permalink/t3tsref:typolink-forceabsoluteurl-scheme@main) is overridden.

#### forceAbsoluteUrl.scheme {#typolink-forceabsoluteurl-scheme}

-   **forceAbsoluteUrl.scheme**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)

    -   *Values:* `http` / `https`
    -   *Default:* `http`

    Defines the URL scheme to be used (https or http). http is the
    default value. Example:

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    typolink {
      parameter = 13
      forceAbsoluteUrl = 1
      forceAbsoluteUrl.scheme = https
    }

    ```

### title {#typolink-title}

-   **title**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main) / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    Sets the title parameter of the A-tag.

### JSwindow_params {#typolink-jswindow-params}

-   **JSwindow_params**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)

    Preset values for opening the window. This example lists almost all
    possible attributes:

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    page.10.typolink.JSwindow_params = status=1,menubar=1,scrollbars=1,resizable=1,location=1,directories=1,toolbar=1
    ```

### returnLast {#typolink-returnlast}

-   **returnLast**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)

    If set to "url", then it will return the URL of the link
    (`$this->lastTypoLinkUrl`).

    If set to `target`, it will return the target of the link.

    So, in these two cases you will not get the value wrapped but the URL
    or target value returned!

    If set to `result`, it will return the json_encoded output of the
    internal `LinkResult` object.

    **Example output**

    ```json
    {
      "href": "/my-page",
      "target": null,
      "class": null,
      "title": null,
      "linkText": "My page",
      "additionalAttributes": []
    }

    ```

### section {#typolink-section}

-   **section**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main) / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    If this value is present, it's prepended with a "#" and placed after
    any internal URL to another page in TYPO3.

    This is used create a link, which jumps from one page directly the
    section on another page.

### ATagParams {#typolink-atagparams}

-   **ATagParams**

    -   *Type:* \<A>-params / [stdWrap](https://docs.typo3.org/permalink/t3tsref:stdwrap@main)

    Additional parameters

    **Example**

    **EXT:site_package/Configuration/Sets/Main/setup.typoscript**

    ```typoscript
    page.10.typolink.ATagParams = class="board"
    ```

### linkAccessRestrictedPages {#typolink-linkaccessrestrictedpages}

-   **linkAccessRestrictedPages**

    -   *Type:* [boolean](https://docs.typo3.org/permalink/t3tsref:data-type-boolean@main)

    If set, typolinks pointing to access restricted pages will still link
    to the page even though the page cannot be accessed.

### userFunc {#typolink-userfunc}

-   **userFunc**

    -   *Type:* [function name](https://docs.typo3.org/permalink/t3tsref:data-type-function-name@main)

    > [!IMPORTANT]
    > <!-- TODO: no Markdown rendering for "versionchanged" -->
    >
    > PHP functions called via TypoScript must now use the PHP
    > attribute #[AsAllowedCallable]
    > (\TYPO3\CMS\Core\Attribute\AsAllowedCallable).

    All of the `typolink` TypoScript configuration will be parsed
    and evaluated by the TYPO3 Core's `LinkFactory->create()` method, and
    then passed on to the defined `userFunc` for further
    manipulation. The `userFunc` needs to return an object
    implementing the
    `LinkResultInterface`. The currently
    calculated typolink is passed as an argument to the `userFunc` as an object
    of the same type. This allows to return either an enriched link, or a
    completely new one.

    The detailed execution steps are:

    First, the `typolink` will be created as configured by the
    specified TypoScript. This will result in an object of Type
    `LinkResultInterface`. This
    immutable object receives all of the TypoScript `typolink`
    configuration as properties, and makes them available via corresponding
    getters. Then your custom `userFunc` is executed and receives
    the following arguments (delivered via
    `$contentObjectRenderer->callUserFunction()`):

    -   **`$content`**

        This contains the object implementing
        `LinkResultInterface`. Inside
        your `userFunc()` you can call for example:

        -   `$content->getUrl()` to get the URL of a link,
        -   `$content->getLinkText()` to get the text of your link
            (everything with the `<a>...</a>` tag),
        -   `$content->getLinkConfiguration()` for the array with all typolink configuration options,
        -   `$content->getAttributes()` returns current anchor link attributes (like `typolink.additionalArguments`),
        -   `$content->getType()` returns the kind of link that is operated on, like
            `LinkService::TYPE_PAGE` (specific pages in your TYPO3 setup) or `LinkService::TYPE_URL`
            for links to external pages.

        See the PHP definition of
        `LinkResultInterface` for the
        full list of getters.

        Since `LinkResultInterface` is
        an immutable object, you must use the methods `withLinkText()`
        and/or `withAttributes()` to create a new object variant, which at
        the end of your `userFunc` must be returned (see below for examples). In
        case you do not make any changes to the object, the function must return
        the original object.

    -   **`$conf`**

        Contains an array of the TypoScript configuration of your `userFunc` parameters.

    -   **`$request`**

        Contains the PSR-7 request object that allows you to operate on your
        current frontend environment and retrieve things like Site Settings,
        current Language, current URL, related
        `ContentObjectRenderer`
        (`$cObj`) and other aspects, see
        [TYPO3 request object](https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/RequestLifeCycle/Typo3Request.html#typo3-request).

    See [Examples for typolink.userFunc](https://docs.typo3.org/permalink/t3tsref:typolink-userfunc-examples@main) for more details.

## Resource references {#typolink-resource-references}

TYPO3 supports a modern and future-proof way of referencing resources using an
extensible and expressive syntax.

In order to understand the syntax, we will guide you through using a simple
page link.

`t3://page?uid=13&campaignCode=ABC123`

The syntax consists of three main parts, much like parts on an URL:

-   **Syntax Namespace (`t3://`)**

    The namespace is set to `t3://` to ensure the `LinkService` should be called
    to parse the URL. This value is fixed and mandatory.

-   **Resource handler key (`page`)**

    The resource handler key is a list of available handlers that TYPO3 can work
    with. At the time of writing these handlers are:

    -   [page](https://docs.typo3.org/permalink/t3tsref:typolink-handler-page@main)
    -   [file](https://docs.typo3.org/permalink/t3tsref:typolink-handler-file@main)
    -   [folder](https://docs.typo3.org/permalink/t3tsref:typolink-handler-folder@main)
    -   [url](https://docs.typo3.org/permalink/t3tsref:typolink-handler-url@main)
    -   [email](https://docs.typo3.org/permalink/t3tsref:typolink-handler-email@main)
    -   [record](https://docs.typo3.org/permalink/t3tsref:typolink-handler-record@main) (see `\TYPO3\CMS\Core\LinkHandling\RecordLinkHandler`)
    -   [phone](https://docs.typo3.org/permalink/t3tsref:typolink-handler-phone@main) (see `\TYPO3\CMS\Core\LinkHandling\TelephoneLinkHandler`)

    More keys can be added via `$GLOBALS['TYPO3_CONF_VARS']['SYS']['linkHandler']` in
    an associative array where the key is the handler key and the value is a
    class implementing the LinkHandlerInterface.

-   **Resource parameters (`?uid=13&campaignCode=ABC123`)**

    These are the specific identification parameters that are used by any
    handler. Note that these may carry additional parameters in order to
    configure the behavior of any handler.

## Handler syntax {#typolink-handler-syntax}

### page {#typolink-handler-page}

-   **page**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/PageLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/PageLinkHandler.php)
    -   *Example:* `t3://page?uid=42&type=3`

    The page identifier is a compound string based on several optional settings.

#### page.uid {#typolink-handler-page-uid}

-   **page.uid**

    -   *Type:* [integer](https://docs.typo3.org/permalink/t3tsref:data-type-integer@main) / [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)
    -   *Example:* `t3://page?uid=13`

    The UID (field `uid`) of a page record, or "current" to reference
    the current page.

    -   `t3://page?uid=13`
    -   `t3://page?uid=current`

#### page.alias {#typolink-handler-page-alias}

-   **page.alias**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)
    -   *Example:* `t3://page?alias=myfunkyalias`

    The alias (field `alias`) of a page record (as an alternative to
    [page.uid](https://docs.typo3.org/permalink/t3tsref:typolink-handler-page-uid@main)).

#### page.type {#typolink-handler-page-type}

-   **page.type**

    -   *Type:* [integer](https://docs.typo3.org/permalink/t3tsref:data-type-integer@main)
    -   *Default:* 0
    -   *Example:* `t3://page?uid=13&type=3`

    The type ([Properties](https://docs.typo3.org/permalink/t3tsref:setup-page-typenum@main) property of the [PAGE object type in TypoScript](https://docs.typo3.org/permalink/t3tsref:page@main) top level
    object). `t3://page?uid=13&type=3` will reference page 13 in type 3.

#### page.parameters {#typolink-handler-page-parameters}

-   **page.parameters**

    -   *Type:* string of parameters
    -   *Example:* `t3://page?uid=1313&my=param&will=get&added=here`

    String of parameters, prefixed with `&`, to be added to the URL.

#### page.fragment {#typolink-handler-page-fragment}

-   **page.fragment**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)
    -   *Example:* `t3://page?uid=13&type=3#123`

    The anchor or section to jump to. Must be prefixed with `#`.

### file {#typolink-handler-file}

-   **file**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/FileLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/FileLinkHandler.php)
    -   *Example:* `t3://file?uid=13`

    Links to a file to download.

#### file.uid {#typolink-handler-file-uid}

-   **file.uid**

    -   *Type:* [integer](https://docs.typo3.org/permalink/t3tsref:data-type-integer@main)
    -   *Example:* `t3://file?uid=13`

    The UID of a file within the file abstraction layer (FAL) database table
    `sys_file`.

#### file.identifier {#typolink-handler-file-identifier}

-   **file.identifier**

    -   *Type:* [integer](https://docs.typo3.org/permalink/t3tsref:data-type-integer@main)
    -   *Example:* `t3://file?identifier=fileadmin/path/myfile.jpg`

    The identifier of a file using combined `<storage>:<path>` reference or a direct
    reference to a file in the default storage with UID `0` as a fallback.

    Examples:

    -   `t3://file?identifier=1:/path/myfile.jpg`
    -   `t3://file?identifier=fileadmin/path/myfile.jpg`

    > [!WARNING]
    > **Attention**
    >
    > `file` cannot resolve links to files in extensions.
    > The files must lie in a storage and be accessible via the backend module
    > **Media**.

### folder {#typolink-handler-folder}

-   **folder**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/FolderLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/FolderLinkHandler.php)
    -   *Example:* `t3://folder?storage=1&identifier=myfolder`

    Links to a folder.

#### folder.identifier {#typolink-handler-folder-identifier}

-   **folder.identifier**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)
    -   *Example:* `t3://folder?identifier=fileadmin`

    The identifier of a given folder.

#### folder.storage {#typolink-handler-folder-storage}

-   **folder.storage**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)
    -   *Example:* `t3://folder?storage=1&identifier=myfolder`
    -   *Default:* 0

    The file abstraction layer (FAL) storage UID to the given folder.

### email {#typolink-handler-email}

-   **email**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/EmailLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/EmailLinkHandler.php)
    -   *Example:* `t3://email?email=mailto:user@example.org`

    Mail address to be used, prefixed with `mailto:`

### url {#typolink-handler-url}

-   **url**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/EmailLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/EmailLinkHandler.php)
    -   *Example:* `t3://url?url=example.org`

    URL to be used, if no scheme is used
    `$GLOBALS['TYPO3_CONF_VARS']['SYS']['defaultScheme']` is prefixed
    automatically. The schemes `javascript:` and `data:` are forbidden for
    security reasons and result in an empty url.

    Query parameters have to be URL-encoded.

    Examples:

    -   `t3://url?url=example.org`
    -   `t3://url?url=https://example.org`
    -   `t3://url?url=https://example.org%26parameter=value`

### record {#typolink-handler-record}

-   **record**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/RecordLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/RecordLinkHandler.php)
    -   *Example:* `t3://record?identifier=my_content&uid=123`

    Can be used to link to a record of a certain table. See also the
    [Record link tutorial in TYPO3 Explained](https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/LinkHandling/Tutorials/RecordLinkBrowser.html#TableRecordLinkBrowserTutorials).

    Parameters [record.identifier](https://docs.typo3.org/permalink/t3tsref:typolink-handler-record-identifier@main) and
    [record.uid](https://docs.typo3.org/permalink/t3tsref:typolink-handler-record-uid@main) are mandatory for this link
    handler.

#### record.identifier {#typolink-handler-record-identifier}

-   **record.identifier**

    -   *Type:* [string](https://docs.typo3.org/permalink/t3tsref:data-type-string@main)

    The (individual) identifier of the link building configuration to be used.

    The same identifier is used as key in the TypoScript configuration of
    the frontend rendering: [Properties of 'config'](https://docs.typo3.org/permalink/t3tsref:setup-config-recordlinks@main) and the [TSconfig
    backend link handler configuration](https://docs.typo3.org/permalink/t3tsref:pagetcemaintables-linkhandler@main)

#### record.uid {#typolink-handler-record-uid}

-   **record.uid**

    -   *Type:* [integer](https://docs.typo3.org/permalink/t3tsref:data-type-integer@main)

    The UID of the referenced record to be linked.

### phone {#typolink-handler-phone}

-   **phone**

    -   *Type:* string of parameters
    -   *Implementation:* [EXT:core/Classes/LinkHandling/TelephoneLinkHandler.php (GitHub)](https://github.com/typo3/typo3/blob/main/typo3/sysext/core/Classes/LinkHandling/TelephoneLinkHandler.php)
    -   *Example:* `t3://phone?phone=tel:+4912345678`

    This link handler sets links to phone numbers using the `tel:` protocol.

## Examples {#typolink-examples}

Create a link to page with uid 2:

**EXT:site_package/Configuration/Sets/Main/setup.typoscript**

```typoscript
page.20 = TEXT
page.20.value = anchor text
page.20.typolink.parameter = 2
```

Output:

**Example output**

```html
<a href="/somepage">anchor text</a>
```

Just display the URL:

**EXT:site_package/Configuration/Sets/Main/setup.typoscript**

```typoscript
page.30 = TEXT
page.30.typolink.parameter = 2
page.30.typolink.returnLast = url
```

Output:

**Example output**

```text
/somepage
```

## Using link handlers {#link-handler}

See [Link handler documentation in "TYPO3 Explained"](https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ApiOverview/LinkHandling/Linkhandler/Index.html#linkhandler).
