I'm trying to create some Python Toolboxes for our ArcMap application (e.g. MyTool.pyt)

I can see that the help text is defined with the classes self.description attribute.

However, once I run the program, and click into any of the parameter fields, the help/description text goes empty. I would like to be able to provide the description field for each parameter. How is this accomplished?

After some responses, I see that via the 'Item Description' right-click context menu there are many fields that may be populated. Is there a 'pythonic' way to do this? That is, just by embedding some attributes in the .pyt file classes?

For instance, in the .pyt toolbox definition you have the Toolbox class:

import arcpy

class Toolbox(object):
    def __init__(self):
        """Define the toolbox (the name of the toolbox is the name of the
        .pyt file)."""
        self.label = "My Toolbox"
        self.alias = ""

        # List of tool classes associated with this toolbox
        self.tools = [MyNiceTool]

class MyNiceTool(object):
    def __init__(self):
        """Define the tool (tool name is the name of the class)."""
        self.label = "My Tool Class"
        self.description = """
A description that shows up in the help context side pane when the tool is launched.
        self.canRunInBackground = True

    def rest_of_required_methods....

From the self.description string the Tool dialog help window will display this text. However, what I am wanting to do is have a 'description' embedded in my code for each parameter also, so that when the tool is launched, and the user clicks into a parameter field, the parameter description is shown. If I were to do this using the 'Item Description' method referenced in the replies below, I would edit the fields Dialog Explanation under the Syntax section for each parameter... I guess.

4 Answers 4


I can see that the help text is defined with the classes self.description attribute.

This is where you are going wrong. In the help page Documenting a tool in a Python toolbox it says:

For Python toolboxes, the documentation for the toolbox and tools are stored in .xml files that are associated with the toolbox and tools by name. The help for each tool will be stored in a separate .xml file.

This means that you cannot set help text from within the .pyt file itself. This makes sense when you consider that the help text is not plain ASCII but rich text that can include formatting, bullets, and images.

Fortunately, Python supports for reading and writing XML, so you should be able to dynamically edit the help text from a separate script.

  • 2
    Thanks for the link to the 'Documenting' help page.. I searched, but for some reason didn't come to that page. It would be nice if ESRI supported restructuredText. Then we could document the toolboxes from the code directly as one can using Sphinx.
    – John
    Commented May 14, 2013 at 22:32
  • "you should be able to dynamically edit the help text from a separate script." --> That would be very desirable.. has anybody developed a tool for this?
    – Ratnanil
    Commented Feb 14, 2018 at 9:06

You can define messages for each parameter by following these steps:

  1. Open ArcCatalog and highlight the Script in the catalog tree
  2. Select the Description tab
  3. Click the Edit button
  4. Click the down arrow next to each parameter and type in a message
  5. Finally, save edits by clicking the Save button

When a users clicks within a script parameter now they will see your message.

  • 4
    Thanks.. do you know where this information is then ultimately saved? Does it get written to the xml files that seem to be created in the folder where i place the .pyt file?
    – John
    Commented May 14, 2013 at 13:02

If I understand correctly, you want to add Help texts to your functions. That can be done by right-clicking your tool from the toolbox window and click Item description and then Edit at the top. It'll allow you to add a description for each parameter, which will show up in the help section when clicking the parameter.

If you are in Arcmap 10.0 (at least earlier SP's) you need to do this from the ArcCatalog window (browse to your toolbox) within Arcmap for it to work.

  • Thanks, this is helpful, and it seems to indeed be a solution. In fact, it opens up a whole new series of questions for me! I didn't realize about all of these 'Item Description' fields, as I've only worked with the toolboxes via the Python Toolboxs (.pyt) files in 10.1. Unfortunately, it is not quite what I was after, though... so I'm going to edit my question now.
    – John
    Commented May 14, 2013 at 12:48

You only need to click on the edit metadata of the tool you will see that for each parameter you can easily edit the messages to display.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.