HOW TO

Batch export layouts in ArcGIS Pro

Last Published: July 12, 2024

Summary

In ArcGIS Pro, a layout can be exported at the page size or clipped to the extent of the elements on the page. However, the Export Layout feature does not support batch exporting of layouts. This article provides the workflow to batch export layouts in ArcGIS Pro using Python, with the option to export the full layout or only the clipped extent.

Procedure

  1. In ArcGIS Pro, on the Insert tab, select New Notebook.
Add a new notebook to the ArcGIS Pro project by navigating to the Insert tab and in the Project group, select New Notebook.
  1. On the New Notebook tab, ensure the cell type is Code.
  2. In the cell's expression box, type the following codes. Replace <file path> with the destination folder path. Set the clip_to_elements parameter to 'True' to export the areas of the page that contains layout elements only instead of the whole layout. This is equivalent to the Clip to graphics extent function in the Export Layout feature. In this example, the parameter is set to 'False' to export the full layouts.
import arcpy,os

aprx = arcpy.mp.ArcGISProject("CURRENT")

for lyt in aprx.listLayouts():

  lyt.exportToPDF(os.path.join(r"<file path>", f"{lyt.name}"), clip_to_elements=False)
The Notebook in ArcGIS Pro containing the Python codes
Note:
The layouts can be exported as other file types by substituting 'exportToPDF' with other exportTo methods. Refer to ArcGIS Pro: Method Overview for the available methods.
  1. Click Run to execute the codes in the cell.
On the New Notebook tab, click the Run button to execute the code in the cell.
  1. The operation status is indicated on the upper-right corner of the New Notebook tab. A filled circle indicates the operation is running.
The filled circle on the upper-right corner of the New Notebook tab indicates that the operation is running in the notebook.

The image below demonstrates the layouts are exported to the destination folder after the operation is completed.

The layouts are exported as PDF files to the destination folder after the operation is completed.

Article ID: 000026961

Software:
  • ArcGIS Pro 3 0
  • ArcGIS Pro 2 8 x
  • ArcGIS Pro 2 7 x
  • ArcGIS Pro 2 x

Receive notifications and find solutions for new or common issues

Get summarized answers and video solutions from our new AI chatbot.

Download the Esri Support App

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options