elementor/delete-element removes the element at a given ID, and everything nested inside it.
Populated and top-level elements need force_delete.
Before you run it
Deleting an element deletes everything inside it. A container holding a whole page section goes with one call, and there is no trash for Elementor elements — the only recovery is a WordPress revision of the post, if revisions are enabled and one was taken. force_delete is required for populated or top-level elements precisely because those are the expensive mistakes.
At a glance
| Ability | elementor/delete-element |
| Toolset | Elementor — toolset/elementor |
| Group | Elementor › Elements & Widgets |
| Requires | Elementor, active on the site |
| Capability | manage_options |
| Safety | Destructive — removes the element and everything inside it. Guarded by force_delete for populated or top-level elements. |
| Repeatable | Not idempotent — each call changes the row set, so re-running is not a no-op |
| Ships in | AcrossAI Abilities Manager 0.0.34 and later |
How it works
The guard is scoped to where the damage is. Deleting an empty widget is cheap and needs no ceremony; deleting a top-level container that holds a third of the page is not, and the two calls otherwise look identical.
So the flag is required exactly where the deletion removes content somebody would miss.
There is no trash. Elementor elements are part of a serialised blob rather than posts, so nothing takes a copy on the way out.
A WordPress revision of the post is the only recovery, and it only exists if revisions are enabled and one was taken since the content was added. Reading the element first with elementor/get-element at least gives you the payload to put back.
Not idempotent, though deleting an ID that is already gone is reported rather than silently succeeding.
Elementor generates a CSS file per post and caches it. A change to the document does not change the rendered page until that CSS is regenerated, which is why elementor/clear-cache is the second half of several operations here.
Input
| Name | Type | Required | What it is |
|---|---|---|---|
post_id | integer | Yes | The post holding the Elementor document. |
element_id | string | Yes | The seven-character hex element ID. |
force_delete | boolean | For populated or top-level elements | Required when the element has children or sits at the document root. |
What comes back
| Name | Type | What it is |
|---|---|---|
post_id | integer | The post written. |
deleted_id | string | The element removed. |
success | boolean | Whether the call completed. |
message | string | A one-line summary of what happened, suitable for showing a human. |
error_code | string | Present only on failure — a stable machine-readable reason, such as a missing field, a wrong field type or an unmet confirmation. |
Example
Ask your assistant:
Delete that empty container.
It resolves to one call:
{
"ability": "elementor/delete-element",
"parameters": {
"post_id": 412,
"element_id": "a1b2c3d"
}
}Worth knowing
- Everything inside goes too. There is no trash for Elementor elements.
- Read the element first — that payload is your only copy.
- Post revisions are the only other recovery, if enabled.
- Clear the Elementor cache afterwards.
Related abilities
- Get Elementor Element — take a copy first
- Remove Elementor Element — the identical alternative name
Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager
Browse the rest: Every ability, by category