Using Custom Variables

Custom Variables is a PLATINUM and Enterprise feature that allows you to pass several variables through a survey link. You can take a survey link that would otherwise collect anonymous responses, and instead pass several values directly into your survey via that URL. When you analyze your results, these values will appear on the last page of the survey.

For example, the survey link would normally collect anonymous responses, but adding custom variables to the end of the URL (like so: would track 3 values into your survey, without having to ask respondents to answer those questions in the survey itself.

There is no limit on the number of variables you can add, but keep universal URL length limitations in mind. The general rule is to keep URLs under 2000 characters to maintain functionality with popular web browsers.

Who should use Custom Variables?

If it's not feasible to use an email invitation collector or simply ask respondents their custom information; you can insert this information for tracking purposes directly into the URL.  This feature is primarily used for companies using panelists that do their analysis external to SurveyMonkey.  For the average SurveyMonkey user, there are limitations to consider:

  • This feature is optimal for projects that use their own JavaScript or scripts to insert the custom variables into the link for them.  There isn't a way within the SurveyMonkey tool itself to automate the uploading of these fields.
  • Filtering on custom variables is a bit more difficult than using close-ended questions because they're collected as open-ended questions.  Again, this is optimal for users that do heavy-duty analysis in their own tools like SPSS or Excel.
  • If using your own custom scripts or SPSS for analysis isn't something you're comfortable with, we recommend using close-ended questions or demographic questions to obtain the same information in the body of the survey.  See more about tracking respondents.

Setting Up Custom Variables

The steps for setting up Custom Variables differ between Classic Design and New Design.

Classic Design

To add custom variables:

  1. From your Design Survey page, click Survey Options.
  2. Scroll down to Add Custom Variables, and click Add Custom Variables.
  3. You'll be prompted to enter a Custom Variable Name and a Custom Variable Label:
    • The Custom Variable Name will appear in the URL string itself, so keep these short and space-free.
    • The Custom Variable Label will appear in your analysis, so this is a descriptive place for you to keep track what the field means.
  4. Enter your values, and click Apply for each variable.
  5. Copy the URL string from Your Survey Link.
  6. Click Save.
New Design

To add custom variables:

  1. Click the Design Survey tab.
  2. In the left sidebar, click LOGIC.
  3. Click Custom Variables.
  4. Set up the first variable by completing the following fields:
    • Variable Name (required) - This will appear in the URL string itself. The Variable Name cannot contain any spaces. Max 50 characters.
    • Label (optional) - This will appear in your analysis, so create a label that will help you track what information the field contains. Max 250 characters.
  5. Click Save.
  6. If you wish to add additional custom variables, click + Add New Custom Variable.

 Which version am I using? »

Modifying the Survey Link

When you create a Web Link collector for a survey with custom variables applied, the custom variables will automatically be appended to the end of the URL. All you need to do is replace the bracketed values with the custom information for each respondent. You can do this with your own scripting or JavaScript; but at this time SurveyMonkey doesn't offer a way to add these values for respondents within the tool.

Each survey link will need to match the following format, where:

  • var1, var2, and var3, are the Variable Names you created in the Design Survey section
  • [value], [value1], and [value2] are the values you must replace with each respondent's custom information[value]&var2=[value2]&var3=[value3]

For example:

If your survey URL is, and you added three custom variables named Name, Department, and Title, then each of your links will need to follow this format:[Name_value]&Department=[Department_value]&Title=[Title_value]

If you were to customize the URL for Doug — an Intern in the Research department, you would replace the bracketed values with his custom information as follows:

When Doug takes the survey through this URL, the custom variables will be tied to his response.

Analyzing Results Using Custom Variables

View custom variables by exporting an All responses data spreadsheet.

Exporting Custom Variable Data

Only the All Responses Collected export will include custom variable data.

lightbulb Some Variable Names are Excluded

This feature permits just about any custom variable name; but there are a few that we already use in our system.  The ones we already utilize aren't allowed to be appended using this feature: