Template components
Updated: Nov 21, 2025 Templates are made up of four primary components which you define when you create a template: header, body, footer, and buttons. The components you choose for each of your templates should be based on your business needs. The only required component is the body component. Some components support variables, whose values you can supply when using the Cloud API or On-Premises API to send the template in a template message. If your templates use variables, you must include sample variable values upon template creation.Text header
Text headers are optional elements that can be added to the top of template messages. Each template may include only one text header. Please note that markdown special characters are not supported in this component, so we recommend avoiding their use. Text headers support 1 parameter.Creation syntax
Creation parameters
Creation example
This example uses 1 named parameter.Media header
Media headers can be an image, video, gif, or a document such as a PDF. All media must be uploaded with the Resumable Upload API. The syntax for defining a media header is the same for all media types. Note: Gifs are currently only available for Marketing Messages API for WhatsApp. Gifs are mp4 files with a max size of 3.5MB and larger files will be displayed as video messages.Creation syntax
Creation parameters
Creation example
Location header
Location headers appear as generic maps at the top of the template and are useful for order tracking, delivery updates, ride-hailing pickup/dropoff, locating physical stores, etc. When tapped, the app user’s default map app will open and load the specified location. Locations are specified when you send the template. Location headers can only be used in templates categorized asUTILITY or MARKETING. Real-time locations are not supported.
Creation syntax
Creation parameters
None.Creation example
Send syntax
Send parameters
Send example
Body
The body component represents the core text of your message template and is a text-only template component. Templates are limited to one body component. The message text in the body component accepts multiple parameters.Creation syntax
Creation parameters
Creation example
Syntax
Properties
Example
Buttons
Buttons are optional interactive components that perform specific actions when tapped. Templates can have a combination of up to 10 button components in total, although there are limits to individual buttons of the same type as well as combination limits, which are described below. In addition, templates composed of 4 or more buttons, or a quick reply button and one or more buttons of another type, cannot be viewed on WhatsApp desktop clients. WhatsApp users who receive one of these template messages will be prompted to view the message on a phone instead. Buttons are defined within a single buttons component object, packed into a singlebuttons array. For example, this template uses a phone number button and a URL button:

