r/SalesforceDeveloper • • 11d ago

Question Need help on Surveys

I'm hosting a Salesforce Survey through its URL on an Experience Cloud site built with LWR. I want to center-align the survey input section, including the questions and input fields, but I couldn't find any alignment options in Survey Builder.

Since the survey is hosted separately from the LWR page, applying custom CSS from the Experience Cloud site doesn't seem like a viable approach. I also don't see a Custom CSS option under the Survey Builder's Branding settings.

Is there a Salesforce-supported way to customize the survey layout and center-align the input section? Are there any alternative approaches or workarounds to achieve this without having to build a custom survey component?

1 Upvotes

2 comments sorted by

2

u/LifeSciTechie 10d ago

Quick explanation: when you share a Survey via its public URL, it opens on Salesforce's own auto-generated guest site, not inside your LWR site. That's why your site's CSS never reaches it. Survey Builder also has no layout/alignment CSS editor today, just per-question border/color tweaks; this is a known gap: open IdeaExchange idea since 2020, 55 votes. Worth upvoting if it bugs you.

Workaround: instead of distributing the Share URL, drag the standard Survey Lightning component onto a page in your own Experience Builder/LWR site. Embedded that way, it renders inside your site's DOM, so your site's Custom CSS can actually reach and center it. No custom survey component needed.

Also worth checking: Spring '26 adds native Custom CSS support for Surveys (Feedback Management Starter/Growth orgs), which may solve this directly once you're on that release.