Skip to main content

Better Messages for RealHomes: Buyer ↔ Agent Live Chat for Real Estate Listings

The RealHomes integration for Better Messages adds a Live Chat row inside the agent contact panel on the single property page (next to Office / Mobile / Email), a Live Chat icon on property listing cards, a Live Chat contact row on agent and agency profile pages, the same row on every card in the agents and agencies listings, plus a Messages tab inside the RealHomes user dashboard at /dashboard/?module=bm-messages. Buyers reach the listing's agent — or the agency owner when no agent is linked — in one click, with the property image, price, beds / baths / sq ft and address pinned to the top of the conversation. Theme accent colors (the value configured in RealHomes Theme Options → Global Styling → Primary Color) are inherited automatically through the --rh-global-color-primary CSS variable. Works on both the free and WebSocket versions.

REQUIREMENTS

To install the plugin ensure that your website running:

  • WordPress 5.9 or newer
  • PHP 7.1 or newer

Installation

How to install RealHomes

The RealHomes – Real Estate WordPress Theme is a commercial theme from Inspiry Themes. Purchase, download and activate it from Appearance → Themes, then install the required Easy Real Estate plugin and (optionally) the Slider Revolution plugin pack that ships with it. Once RealHomes is active you'll get the property, agent, and agency post types, the user dashboard at /dashboard/, the half-map property search, and the property submission flow out of the box.

How to install Better Messages with RealHomes

  1. Install Better Messages through the WordPress plugins screen or upload the plugin files to the /wp-content/plugins/bp-better-messages directory.
  2. Activate the plugin through the Plugins screen in WordPress.
  3. Use the Better Messages → Settings menu to configure the plugin.
  4. Go to Settings → Integrations → Directories and enable the Enable RealHomes Integration toggle. Each placement below has its own toggle so you can enable only the ones you want.

RealHomes integration settings

Setting the RealHomes dashboard as the messages location

Better Messages → Settings → General has a Messages Location dropdown that controls which page hosts the user inbox. Selecting Show in RealHomes Dashboard routes every "open inbox" link in the plugin (notification emails, on-site links, push notifications, the floating bubble, etc.) into the Messages tab inside the RealHomes dashboard at /dashboard/?module=bm-messages. The dashboard tab is force-enabled and locked while this option is selected — change the Messages Location away from RealHomes to unlock it again.

When this option is active the messenger renders full-screen inside the dashboard frame — same RealHomes sidebar, same dashboard chrome, edge-to-edge messenger surface, no rounded card border. The page-head breadcrumbs are hidden so the conversation pane takes the full available height.

Messages Location dropdown with "Show in RealHomes Dashboard" selected

Supported features

Live Chat row on the single property page

Renders inside each agent's contact card in the property sidebar, alongside the native Office / Mobile / WhatsApp / Fax / Email rows. Each agent linked to the property gets their own button so buyers can pick which agent to message. The button is hidden when the property is unpublished or when the visitor is also the listing's author. Colors match whatever you have configured in RealHomes Theme Options → Global Styling → Primary Color.

Property page

Live Chat icon on property cards

Adds a small circular icon button to the action row already present on RealHomes v4 property cards (grid and list views), matching the styling of the native Favorite / Compare icons exactly — same 32×32 size, same accent color, same hover transition (filled accent background with white icon). Hidden for cards owned by the current visitor. Hover tooltip uses RealHomes' own rh-ui-tooltip so the popup matches the native "Add to compare" / "Add to favorites" tooltips.

Listing grid

Listing list

Live Chat row on agent profile pages

Adds a Live Chat row to the contact list on the agent profile page, between the native Office / Mobile / Email rows. The button targets the WordPress user linked to the agent through the User Agent/Agency/Owner ID mapping in the WP user profile (the inspiry_role_post_id user meta). When no linked user exists, the conversation is silently routed to the property's post_author and the buyer still sees the agent's name and headshot — see the persona section below.

Agent profile

Live Chat row on agency profile pages

Same treatment for agency profile pages — the button targets the WordPress user that owns the agency CPT, which is typically the brokerage owner.

Agency profile

Live Chat row on agent and agency listing cards

The same contact-item layout appears on every card on the Agents (/our-agents/) and Agencies (/agencies/) listings, next to the agent's Office / Mobile / Email so buyers can start a conversation without opening the profile first.

Agents listing with Live Chat row on every card

Messages tab inside the RealHomes dashboard

Adds a Messages entry to the dashboard sidebar at /dashboard/, sitting between My Saved Searches and My Profile. The tab is registered through the theme's native realhomes_dashboard_menu filter, so it renders server-side with the same markup as every other dashboard module — same icon position, same active-state styling, same responsive collapse behaviour. Clicking the tab loads the full Better Messages inbox inline at /dashboard/?module=bm-messages, dropping the messenger into the dashboard content area between the existing sidebar and topbar.

The integration does not replace RealHomes' built-in CRM Inquiries panel — both can coexist. If you want the native one gone, enable Hide Native Inquiries Tab in the integration settings; the crm/inquiries sub-item is removed from the Properties CRM submenu so users only see the Better Messages tab.

RealHomes dashboard with messenger loaded inline

Live unread badge on the Messages tab

The Messages entry in the dashboard sidebar carries a live unread badge — a small circle with the total number of unread messages — so users see new inquiries from anywhere in the dashboard. It updates the instant a message arrives (WebSocket version) or within a few seconds via polling (free version), and clears as soon as the user opens the unread thread. The same badge is mirrored on the Messages link inside the header user-avatar dropdown, so an agent never has to land on the dashboard to know there's something new. Page title is also prefixed with (N) while the count is above zero.

RealHomes dashboard sidebar with a "1" unread badge on the Messages tab

A Messages link is also injected into the header user-avatar dropdown (the menu that appears when you click your avatar in the top bar), positioned right before My Profile. It links to the same /dashboard/?module=bm-messages URL and shows the same unread badge, so buyers and agents can jump to the inbox from any page on the site without having to open the dashboard first.

Listing info card inside the conversation

Conversations started from a property page or listing card show the property's image, title, price, basic specs (beds / baths / sq ft) and address pinned to the top of the messenger. Clicking the property opens the listing in a new tab.

Example: buyer ↔ agent conversation

A real exchange between a buyer (John Doe) and an agent (Melissa William) about the Home in Merrick Way. The property context card (For Sale badge, photo, price, beds / baths / sq ft, address) is pinned at the top — the yellow "Chatting as Melissa William" banner just below tells the routed receiver which agent persona this conversation is attributed to. Messages flow naturally back and forth on the same surface, no email roundtrip.

Buyer ↔ agent conversation on the RealHomes dashboard with property context card and persona banner

Agent / agency persona inside every thread

Buyers always see the agent or agency CPT identity as the other side of the conversation — never the underlying WordPress account. The thread sidebar, conversation header, message sender chips, info panel, mini chat widget and call screen all show the agent's full name and headshot (or agency name and logo) from the RealHomes CPT, with a clickable link straight to the agent / agency profile page.

This works even when the agent or agency CPT has no linked WordPress user — the chat is silently routed to the property's post_author (or the agency owner), but the buyer still sees the persona's name, photo and profile URL. A single fallback account can route inquiries for several different agents at once and the buyer sees each conversation as a chat with a distinct agent.

On the routed receiver's side, the messenger keeps their real WordPress identity in the bottom-left profile widget (no leakage into self-view) and shows a yellow "Chatting as [Agent name]" banner above the property card, so they always know which persona the buyer thinks they are talking to.

This is a reusable Better Messages mechanism — see the developer guide on per-thread "fake users" for how the same pattern is built into Better Messages and how to reuse it in your own integrations.

Shortcodes for custom placement

If the auto-injected buttons don't land where you want them (custom Elementor template, sidebar widget, theme override, etc.), drop the matching shortcode wherever you need.

info

Disable the corresponding toggle (Property Page Button / Agent and Agency Profile Button / Property Card Button / Agent Listing Card Button) before placing the shortcode, otherwise the button will be rendered twice — once auto-injected and once by the shortcode.

[better_messages_realhomes_property_button]

Renders the Live Chat button targeted at one of the property's agents. Uses the current property when no property_id is supplied and the property's first published agent.

AttributeDefaultNotes
property_idcurrent propertyOverride the property the button targets
agent_idfirst published agent on the propertyOverride which agent receives the conversation
textLive ChatOverride the button label
[better_messages_realhomes_property_button]
[better_messages_realhomes_property_button property_id="101"]
[better_messages_realhomes_property_button agent_id="57"]

[better_messages_realhomes_property_card_button]

Renders the smaller card-style Live Chat icon button used inside listing cards.

AttributeDefaultNotes
property_idcurrent propertyOverride the property the button targets
textLive ChatTooltip text (the button is icon-only)
[better_messages_realhomes_property_card_button]
[better_messages_realhomes_property_card_button property_id="101"]

[better_messages_realhomes_agent_button]

Renders the Live Chat button targeted at the agent's linked WordPress user. Pass style="contact-item" to get the small inline contact-row variant (same as the auto-injected one in the contacts list); omit it to get the full-width primary button.

AttributeDefaultNotes
agent_idcurrent agentOverride the agent post the button targets
stylefull-width buttonPass contact-item for the inline contact-row variant
textLive Chat / Send a messageOverride the visible label
[better_messages_realhomes_agent_button]
[better_messages_realhomes_agent_button agent_id="57"]
[better_messages_realhomes_agent_button style="contact-item"]

[better_messages_realhomes_agency_button]

Renders the Live Chat button targeted at the agency's linked WordPress user. Same attributes as the agent shortcode.

[better_messages_realhomes_agency_button]
[better_messages_realhomes_agency_button agency_id="4577"]
[better_messages_realhomes_agency_button style="contact-item"]

Theme color inheritance

The Live Chat buttons read RealHomes' own --rh-global-color-primary CSS variable (set from Theme Options → Global Styling → Primary Color) and use it for the button background, the property-card icon accent, the price label inside the thread context card, and the dashboard sidebar highlight. Change the RealHomes primary color and every Better Messages surface updates on the next page load — no extra configuration needed, no PHP options to read, no caching to flush.

Frequently asked questions

Does it work with all RealHomes design variations?

Yes. The integration's DOM selectors match the ultra, modern and classic design variations, plus the Elementor templates RealHomes Studio ships. For property cards rendered through custom Elementor templates or page builder widgets that don't follow the v4 grid / list templates, use the [better_messages_realhomes_property_card_button] shortcode inside the template if the auto-injection doesn't catch the custom widget.

Should I disable the native RealHomes CRM Inquiries panel?

It's optional. The two systems coexist — the RealHomes CRM keeps the email-inquiry workflow it always had (when buyers submit the Send Message form on a listing), Better Messages adds the real-time conversation channel on the same page. If you want a single inbox, enable Hide Native Inquiries Tab in the integration settings; the crm/inquiries sub-item is removed from the dashboard sidebar.

Can buyers chat without registering?

Yes — if Guest Chat is enabled in Better Messages → Settings → General → Guest Chat, anonymous visitors can use the Live Chat buttons without logging in. The RealHomes user dashboard requires login, so the Guest Chat row also exposes a Guest Messages Page picker — set it to a regular public WordPress page (or one-click create one) and guests reach the messenger there from every chat trigger and email link. See Guest access → Guest Messages Page.

What happens when a property is unpublished?

The Live Chat button is hidden when the property is not published. Existing threads remain readable.

Does it work on agent or agency CPTs that don't have a linked WordPress user?

Yes. When the agent or agency CPT has no WordPress user linked through the User Agent/Agency/Owner ID mapping, the chat is silently routed to the property's post_author (or the agency owner). The buyer still sees the agent's name, headshot and profile URL in the conversation — the routed receiver sees a yellow "Chatting as [Agent name]" banner above the property card so they know which persona the buyer is contacting. The same fallback account can host inquiries for several different agent CPTs and every thread still shows its own distinct persona to the buyer.

The link is appended to the .agent-contacts-list flex container that holds the native Office / Mobile / Email rows, so it naturally fills the next column in the responsive grid. To move it elsewhere, disable the Agent and Agency Profile Button toggle and drop the [better_messages_realhomes_agent_button style="contact-item"] shortcode wherever you want it.

See also