> This page is for Designer API.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developers.webflow.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developers.webflow.com/_mcp/server.

# Get component

## **`ComponentElement.getComponent()`**

Get the Component Definition associated to a Component Instance

### Syntax

```typescript
element.getComponent(): Promise<Component>
```

### Returns

**Promise\<*Component*>**

A promise that resolves to a Component Object associated with a Component Instance.

```typescript
//Get User Selected Element from the Designer
const parent = await webflow.getSelectedElement();

// Check if this selected element is a Component Instance
if(parent && !parent.configurable && parent.type === 'ComponentInstance'){
      console.log(await parent.getComponent().getName());
    }
```

### Designer Ability

Checks for authorization only

| Designer Ability    | Locale | Branch | Workflow | Sitemode |
| :------------------ | :----- | :----- | :------- | :------- |
| **canAccessCanvas** | any    | any    | any      | any      |