Card block
A bordered card with an icon, title, subtitle, hero image, body text, and actions.
card lays out a small piece of content (an icon or image, a title and subtitle, a hero image, body
text, and buttons) inside a bordered box. It’s a library-invented block, not part of the public
@slack/types package; use it standalone or as an item inside a carousel.
Fields
typestring
Always card.
stringicon?{ type: "image"; image_url: string; alt_text?: string }
A 36×36 rounded icon, left of the title and subtitle. Takes precedence over slack_icon.
{ type: "image"; image_url: string; alt_text?: string }slack_icon?{ type: "icon"; name: string }
One of Slack's icons, by name. rocket, calendar, bug, lightbulb, star-filled and warning are drawn with Slack's own glyphs; any other name shows a neutral badge with the icon's name in a tooltip.
{ type: "icon"; name: string }title?PlainTextElement | MrkdwnElement
The card's bold title, cut to one line after its last whole word that fits.
PlainTextElement | MrkdwnElementsubtitle?PlainTextElement | MrkdwnElement
Muted text under the title, cut to one line after its last whole word that fits.
PlainTextElement | MrkdwnElementhero_image?{ type: "image"; image_url: string; alt_text?: string }
A full-width image above the header.
{ type: "image"; image_url: string; alt_text?: string }body?PlainTextElement | MrkdwnElement
The card's main text.
PlainTextElement | MrkdwnElementsubtext?PlainTextElement | MrkdwnElement
Fine print below the body.
PlainTextElement | MrkdwnElementactions?Element[]
Buttons and other interactive elements, rendered along the bottom of the card.
Element[]block_id?string
A unique identifier, up to 255 characters. Actions from the card's buttons carry it as their block_id.
stringExamples
With and without a hero image
With and without an icon
With and without a subtitle
Dropping subtitle centers a lone title on the icon instead of stacking the two.
Subtext and multiple actions
Slack orders a card’s buttons by style, regardless of where they appear in actions: danger
buttons first, then default buttons and finally primary ones. Buttons with the same style keep their
order from actions. With three buttons, the danger ones sit on the left and the rest on the right;
with one or two, all of them sit together on the right.
Interactivity
Each entry in actions is a standard interactive element, most often a button, and dispatches
Slack’s block_actions payload the same way an actions block does. Click a button
in any preview above and check the action log: onAction receives
{
"type": "button",
"action_id": "button_action",
"block_id": "<the card's block_id>",
"text": { "type": "plain_text", "text": "Action Button", "emoji": false },
"value": "…"
}
alongside the full block_actions payload your app’s request URL would receive.

