> 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 variable mode breakpoint

> Learn how to get the breakpoint that drives a variable mode.

## `mode.getBreakpoint()`

Get the [breakpoint](https://help.webflow.com/hc/en-us/articles/33961300305811) that drives a variable mode. Automatic modes return their `BreakpointId`. Manual modes return `null`.

#

### Syntax

```typescript
mode.getBreakpoint(): Promise<BreakpointId | null>
```

### Returns

**Promise\<*BreakpointId | null*>**: `"xxl" | "xl" | "large" | "main" | "medium" | "small" | "tiny"`

A Promise that resolves to the `BreakpointId` for an automatic mode, or `null` for a manual mode.

#

### Example

```typescript
// Get Collection
const collection = await webflow.getDefaultVariableCollection()

// Get Variable Mode
const variableMode = await collection?.getVariableModeByName(modeName)

try {
  // Get the breakpoint that drives the mode
  const breakpointId = await variableMode?.getBreakpoint()

  if (breakpointId != null) {
    console.log(`Automatic mode driven by the "${breakpointId}" breakpoint`)
  } else {
    console.log("Manual mode")
  }
} catch (err) {
  if (err.cause?.tag === "VariableModeInvalid") {
    // The mode no longer exists or has been removed
    console.warn(err.message)
  } else {
    throw err
  }
}
```

[Try this example](https://webflow.com/oauth/authorize?response_type=code\&client_id=19511de1ec410f9228d8dcbc9420e67916dea80d86d18f0c9a533eb475ea0f62)

> **Warning**
>
> A `getBreakpoint` call rejects with a `VariableModeInvalid` error when the mode no longer exists or has been removed (`Variable mode with id "X" not found`).
>
> Catch this error to recover gracefully and surface the message to the user.

### Designer Ability

| Designer Ability     | Locale | Branch | Workflow | Sitemode |
| :------------------- | :----- | :----- | :------- | :------- |
| **canReadVariables** | Any    | Any    | Any      | Any      |