> ## Documentation Index
> Fetch the complete documentation index at: https://docs.retellai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Agent Transfer

In advanced call flows, it's common to switch the handling agent, transferring the conversation from one AI agent to another. **Agent Transfer** (also known as **Agent Swap**) enables you to modularize tasks and re-use specialized agents without relying on [traditional phone-based transfers](/build/single-multi-prompt/transfer-call). Examples include:

* Transferring from a front-desk agent to an appointment-booking agent based on task.
* Transferring from an agent speaking one language to another agent handling a different language, based on user preference.

## Why Use Agent Transfer Instead of Call Transfer?

Compared to transferring to another agent using [transfer call](/build/single-multi-prompt/transfer-call), **Agent Transfer** offers significant advantages:

* **Lower Latency**: The transition between agents is near-instant, much lower than transfer call.
* **Better Reliability**: No need to create a new phone call, avoiding potential telephony failures.
* **No Handoff Message Needed**: The destination agent has access to the full conversation history, eliminating the need for adding hand-off messages or repeated customer questions.
* **No Separate Numbers for Agents**: Agents receiving transfers don’t need their own phone numbers — one number is all you need, no matter how many agents you transfer to.

## Transfer Settings Behavior

The following settings of the first agent will be used throughout the call:

* optInSignedUrl
* optOutSensitiveDataStorage
* webHookUrl

All other settings — such as language, voice, and voiceModel — will reflect the currently active agent.

## Steps

<Steps>
  <Step title="Add Agent Transfer Tool">
    Click Add in the tools section and select "Agent Transfer" from the dropdown menu.

    <Frame>
      <img height="700" src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/multi-prompt/transfer_agent.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=93cc0e90a6ef55b5d919bd04368a1fb1" data-path="images/multi-prompt/transfer_agent.png" />
    </Frame>
  </Step>

  <Step title="Configure Details">
    You can configure the following main settings:

    * **Transfer agent**: the ID and version of a specific agent to transfer to. You can select the latest version as well.
    * **Speak during execution and messages**: if the agent should speak something while performing the transfer.
    * **Post call analysis setting**: for post-call analysis, only extract dynamic variables for the transferred agent, or both agents.

    <Frame>
      <img height="700" src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/multi-prompt/transfer_agent_detail.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=2dbaafc521eb828d82ba37c75eb6881b" data-path="images/multi-prompt/transfer_agent_detail.png" />
    </Frame>
  </Step>

  <Step title="Update the Prompt to Enable Agent Transfer">
    Ensure the AI agent knows when and why to trigger the agent transfer. Add clear instructions in the prompt such as:

    * `"If the user asks to book an appointment, use the agent_transfer tool to transfer to the Appointment Agent."`

    <Frame>
      <img height="700" src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/multi-prompt/agent_transfer_prompt.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=3b2f7d8e892240fbc46ca0fbe0096ad5" data-path="images/multi-prompt/agent_transfer_prompt.png" />
    </Frame>
  </Step>

  <Step title="Test and Debug">
    You can test agent transfer both in web call and playground.

    <Frame>
      <img height="700" src="https://mintcdn.com/retellai/M9QYKZE4hbt00HfL/images/multi-prompt/playground_test.png?fit=max&auto=format&n=M9QYKZE4hbt00HfL&q=85&s=c349f16a44ce7c1f69b0d58a711c7e3e" data-path="images/multi-prompt/playground_test.png" />
    </Frame>
  </Step>
</Steps>
