The process of building custom applications and tools that interact with Microsoft SharePoint, including SharePoint Online in Microsoft 365.
Thank you for posting question to Microsoft Q&A forum.
Based on the information you shared, I understand that your SharePoint site renders correctly for internal users, but guest users see a broken UI because custom CSS/JS files hosted in the Private CDN return 403 Forbidden.
After reviewing similar scenarios, the behavior you are seeing is not typically related to user profile synchronization. The SharePoint Online Private CDN does not require guest users to have a synced User Profile in the host tenant to obtain the token used for asset requests. Instead, it relies on standard SharePoint permissions and Azure AD authentication tokens to determine whether a user can access the origin library (usually Site Assets).
A common cause of this issue is the permission configuration. In particular, the group “Everyone except external users” explicitly excludes guest users. This means that even if that group has Read access to the Site Assets library, external users will still be denied access, which results in the 403 responses you are seeing from the CDN.
You may want to review the following points:
- Grant direct read permissions to guest users or to a group that includes them for the library used as the CDN origin (for example, the Site Assets library).
- Ensure that the guest users have properly accepted the invitation and exist as guest identities in your tenant.
- Confirm that the assets being served through the CDN are located in a library where external sharing and guest access are allowed.
If granting permissions directly to guest users is not feasible for your scenario, another approach is to host those static assets using the Public CDN instead of the Private CDN. Public CDN content does not require authentication and therefore avoids permission-related 403 errors for external users.
I hope this helps clarify the behavior.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.