---
schema_version: "1"
id: e56e58dacc0c6b32d85ac7f48b0f15a5a89431d11c64cb2dfb2a54a3bdea9235
title: RemoteSiteSetting
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/api_meta/meta_remotesitesetting.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_remotesitesetting.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: b27ef8dc3b70e073581fe43cbbe216810fbbaef0c6756e59c942ef1660af8fc4
description: Represents a remote site setting. Before any Visualforce page, Apex callout, or JavaScript code using XmlHttpRequest in an s-control or custom button can call an external site, that site must be registered in the Remote Site Settings page, or the call fails.
---
# RemoteSiteSetting

Represents a remote site setting. Before any Visualforce page, Apex callout, or JavaScript code using XmlHttpRequest in an s-control or custom button can call an external site, that site must be registered in the Remote Site Settings page, or the call fails.

[RemoteSiteSetting](#meta_remotesitesetting "Represents a remote site setting. Before any Visualforce page, Apex callout, or JavaScript code using XmlHttpRequest in an s-control or custom button can call an external site, that site must be registered in the Remote Site Settings page, or the call fails.") extends the [Metadata](https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/metadata.htm "The base class for all metadata types. You can’t edit this object. A component is an instance of a metadata type.") metadata type and inherits its fullName field.

## Declarative Metadata File Suffix and Directory Location

[RemoteSiteSetting](#meta_remotesitesetting "Represents a remote site setting. Before any Visualforce page, Apex callout, or JavaScript code using XmlHttpRequest in an s-control or custom button can call an external site, that site must be registered in the Remote Site Settings page, or the call fails.") components are stored in the remoteSiteSettings directory of the corresponding package directory. The file name matches the unique name of the remote site setting, and the extension is .remoteSite.

## Version

[RemoteSiteSetting](#meta_remotesitesetting "Represents a remote site setting. Before any Visualforce page, Apex callout, or JavaScript code using XmlHttpRequest in an s-control or custom button can call an external site, that site must be registered in the Remote Site Settings page, or the call fails.") components are available in API version 19.0 and later.

## Fields

<table class="featureTable sort_table" summary="">



          <thead class="thead sorted" align="left">
            <tr>
              <th class="featureTableHeader  " id="d806309e119">Field</th>

              <th class="featureTableHeader  " id="d806309e122">Field Type</th>

              <th class="featureTableHeader  " id="d806309e125">Description</th>

            </tr>

          </thead>

          <tbody class="tbody">
            <tr>
              <td class="entry" headers="d806309e119" data-title="Field"><span class="keyword parmname">description</span></td>

              <td class="entry" headers="d806309e122" data-title="Field Type">string</td>

              <td class="entry" headers="d806309e125" data-title="Description">The description explaining what this remote site setting is used
                for.</td>

            </tr>

            <tr>
              <td class="entry" headers="d806309e119" data-title="Field"><span class="keyword parmname">disableProtocolSecurity</span></td>

              <td class="entry" headers="d806309e122" data-title="Field Type">boolean</td>

              <td class="entry" headers="d806309e125" data-title="Description">Required. Indicates whether code within Salesforce
                can access the remote site regardless of whether the user's
                connection is over HTTP or HTTPS (<samp class="codeph java">true</samp>) or not (<samp class="codeph java">false</samp>). When <samp class="codeph java">true</samp>, code
                within Salesforce can pass data from an HTTPS session to an HTTP session,
                and vice versa.
                <p class="p">Only set to <samp class="codeph java">true</samp> if you understand
                  the security implications.</p>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d806309e119" data-title="Field"><span class="keyword parmname">fullName</span></td>

              <td class="entry" headers="d806309e122" data-title="Field Type">string</td>

              <td class="entry" headers="d806309e125" data-title="Description">The name can only contain characters, letters, and the underscore
                (_) character. The name must start with a letter, and can’t end with
                an underscore or contain two consecutive underscore
                characters.<p class="p">Inherited from the <a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/metadata.htm" title="The base class for all metadata types. You can’t edit this object. A component is an instance of a metadata type.">Metadata</a> component, this field isn’t defined in
                  the WSDL for this component. It must be specified when creating,
                  updating, or deleting. See <a class="xref" href="https://developer.salesforce.com/docs/atlas.en-us.api_meta.meta/api_meta/meta_create.htm" title="Deprecated. Adds one or more new metadata components to your organization asynchronously. This call is removed as of API version 31.0 and is available in earlier versions only. Use createMetadata() instead.">create()</a> to see an example of this field
                  specified for a call.</p>
              </td>

            </tr>

            <tr>
              <td class="entry" headers="d806309e119" data-title="Field"><span class="keyword parmname">isActive</span></td>

              <td class="entry" headers="d806309e122" data-title="Field Type">boolean</td>

              <td class="entry" headers="d806309e125" data-title="Description">Required. Indicates if the remote site setting is active (<samp class="codeph java">true</samp>) or not (<samp class="codeph java">false</samp>).</td>

            </tr>

            <tr>
              <td class="entry" headers="d806309e119" data-title="Field"><span class="keyword parmname">url</span></td>

              <td class="entry" headers="d806309e122" data-title="Field Type">string</td>

              <td class="entry" headers="d806309e125" data-title="Description">Required. The URL for the remote site.</td>

            </tr>

          </tbody>

        </table>

## Declarative Metadata Sample Definition

A sample XML definition of a remote site setting is shown in this code block.

<?xml version="1.0" encoding="UTF-8"?>
<RemoteSiteSetting xmlns="http://soap.sforce.com/2006/04/metadata">
    <description\>Used for Apex callout to mapping web service</description\>
    <disableProtocolSecurity\>false</disableProtocolSecurity\>
    <isActive\>true</isActive\>
    <url\>https://www.maptestsite.net/mapping1</url\>
</RemoteSiteSetting\>