Update page

Use this API to modify attributes of a Notion page, such as its properties, icon, or cover.

Use cases

Updating properties

To change the properties of a page in a data source, use the properties body parameter. This parameter can only be used if the page's parent is a data source, aside from updating the title of a page outside of a data source.

The page’s properties schema must match the parent data source's properties.

Setting the icon, cover, or "in trash" status

This endpoint can be used to update any page icon or cover, and can be used to archive or restore any page.

Locking and unlocking a page

Use the is_locked boolean parameter to lock or unlock the page from being further edited in the Notion app UI. Note that this setting doesn't affect the ability to update the page using the API.

Applying a page template

Use the template body parameter object to apply a template to an existing page. This can either be the parent data source's default template (type=default), or a specific template (type=template_id).

After the API request finishes, Notion's systems merge the content and properties from your chosen template into the current page.

For more information, visit our related guide: Creating pages from templates.

Erasing content from a page

Use the erase_content flag to delete all block children of the current page. Use caution with this parameter, since this is a destructive action that cannot be reversed using the API.

The main use case is for applying a template in scenarios where it makes sense to clear all of the existing page content and replace it with the template page's content, instead of appending the template content to what's already on the page.

Adding content to a page

To add content, use the append block children API instead. The page_id can be passed as the block_id when adding block children to the page.

General behavior

Returns the updated page object.

📘

Requirements

Your integration must have update content capabilities on the target page in order to call this endpoint. To update your integrations capabilities, navigation to the My integrations dashboard, select your integration, go to the Capabilities tab, and update your settings as needed.

Attempting a query without update content capabilities returns an HTTP response with a 403 status code.

🚧

Limitations

Errors

Each Public API endpoint can return several possible error codes. See the Error codes section of the Status codes documentation for more information.

Language