In this tutorial, we’ll show you how you can use Rank Math to display your Local Business location data using shortcodes.
Fortunately, if you’re using the Gutenberg Block Editor, this is even easier as we have a Local Business by Rank Math Block that makes it extremely easy to add Location Data for Multiple Locations, as shown below:

However, if you’re using the Classic Editor or a page builder (such as Elementor), using the Location Data shortcode is the easiest way to add this to your posts & pages.
To get started, open Rank Math’s Schema Generator, accessible via the sidebar in the Gutenberg Block Editor

Or from Rank Math’s Metabox which is visible in the Classic Editor typically at the end after the post edit area:

Once opened, you’ll see the LocalBusiness Schema. Proceed to edit – which will bring up the following screen where you can find your location’s shortcode:

The Location ID is the Post ID of the Rank Math Location post that you’ll create for a location:

When using Rank Math PRO’s Local SEO Module to create multiple locations – you can easily auto-generate your KML sitemap for business locations. Learn more here.
Rank Math’s Local SEO Attributes
Rank Math makes the following attributes available:
Type
This attribute lets you mention the address, opening-hours, map, store-locator. By default it is set to address.
type
Locations
This attribute is the ID of the location to be shown. By default it is set to show all locations.
locations
Terms
This attribute indicates the location to show from a specific Location category.
terms
Limit
This attribute indicates the number of location to show.
limit
Show Company Name
By default this attribute is set to true and displays the name of the company.
show_company_name
Show On One Line
This attribute displays the company’s address in one line. By default it is set to false.
show_on_one_line
Show State
This attribute displays the State of your Business and by default, it is set to true.
show_state
Show Country
This attribute displays the country’s name of your Business and by default, it is set to true.
show_country
Show Telephone
This attribute displays the telephone number and by default is set to true.
show_telephone
Show Secondary Number
This attribute displays the secondary number and by default is set to true.
show_secondary_number
Show Fax
This attribute displays the fax and by default it is set to false.
show_fax
Show Email
This attribute displays the email address and by default it is set to true.
show_email
Show Logo
This attribute displays the logo and by default it is set to true.
show_logo
Show VAT ID
This attribute displays the VAT ID and by default it is set to false.
show_vat_id
Show Tax ID
This attribute displays the tax ID and by default it is set to false.
show_tax_id
Show Chamber of Commerce ID
This attribute displays the chamber of commerce ID and by default it is set to false.
show_coc_id
Show Price Range
This attribute displays the price range and by default it is set to false.
show_priceRange
Show Opening Hours
This attribute displays the opening hours of your business and by default it is set to false.
show_opening_hours
Show Days
This attribute displays the opening hour of a specific day. Default Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday.
show_days
Hide Closed Days
This attribute hides the days when your business is closed or not working. By default it is set to false.
hide_closed_days
Show Opening Now Label
This attribute displays the Open Now label when a company is currently open based on the user’s timezone. It is enabled by default.
show_opening_now_label
Opening Hours Note
This attribute adds a note after Opening hours data.
opening_hours_note
Show Map
This attribute displays the map and is by default it is set to false.
show_map
Map Style
This attribute displays the map style. By default it shows roadmap.
map_style
Map Width
This attribute displays the width of the map. By default it is set to 100%.
map_width
Map Height
This attribute displays the height of the map. By default it is set to 300px.
map_height
Zoom Level
This attribute displays the map zoom level. By default it is set to -1.
zoom_level
Allow Zoom
This attribute is used in map and lets you zoom. By default it is set to true.
allow_zoom
Allow Scrolling
This attribute is used in the map and allows scrolling. By default, it is set to true.
allow_scrolling
Allow Dragging
This attribute is used in the map and allows dragging. By default, it is set to true.
allow_dragging
Show Route Planner
This attribute is used in map to display the route planner. By default, it is set to true.
show_route_planner
Route Label
This attribute is used in map and you can use the value from the Settings.
route_label
Show Category Filter
This attribute filters displays filter locations by Category
dropdown in Map. By default, it is set to false.
show_category_filter
Show Marker Clustering
This attribute is used in map and by default it is set to false.
show_marker_clustering
Show Info Window
This attribute is used in map and by default it is set to true.
show_infowindow
Show Radius
This attribute displays the radius and is used in the map. By default, it is set to true.
show_radius
Show Nearest Location
This attribute displays whether to show the Location nearest to the current location of the user. By default, it is set to true.
show_nearest_location
Search Radius
This attribute is used in Store Location to search locations within the given radius – Default 10 in kilometers, can be changed to miles from the Titles & Meta settings as shown below:

We hope that this tutorial has helped you to display the location data using a shortcode. However, if you still have any queries please feel free to contact our support team and they’d be happy to help you at any given time.