WordPress Integration Guide
This guide covers how to embed StorySplat 3D scenes in WordPress using the official StorySplat Viewer plugin.
Installation
From WordPress.org (Recommended)
- Go to Plugins → Add New in your WordPress dashboard
- Search for "StorySplat Viewer"
- Click Install Now, then Activate
Manual Installation
- Download the plugin from GitHub
- Upload to
/wp-content/plugins/storysplat-viewer/ - Activate through the Plugins menu
Quick Start
Using the Shortcode
Add this to any post or page:
Using the Gutenberg Block
- Add a new block in the editor
- Search for "StorySplat 3D Scene"
- Enter your Scene ID in the block settings
Shortcode Attributes
| Attribute | Description | Default |
|---|---|---|
scene |
Your StorySplat scene ID (required) | - |
height |
Height of the viewer | 600px |
autoplay |
Auto-start tour playback | false |
showui |
Show navigation controls | true |
lazyload |
Show thumbnail first | false |
class |
Custom CSS class | - |
id |
Custom container ID | - |
Examples
Basic embed:
Custom height with autoplay:
Lazy loading for performance:
Full viewport height:
Gutenberg Block
The StorySplat Gutenberg block provides a visual interface for embedding scenes:
- Scene ID - Enter your StorySplat scene ID
- Height - Set the viewer height
- Auto-play - Toggle automatic tour playback
- Show Navigation UI - Toggle navigation controls
- Lazy Load - Show thumbnail before loading
The block shows a preview in the editor and renders the full viewer on the frontend.
Settings Page
Configure default settings at Settings → StorySplat Viewer:
- Default Height - Default viewer height for all embeds
- Auto-play by Default - Enable autoplay by default
- Show Navigation UI - Show controls by default
These defaults can be overridden per-shortcode or per-block.
Getting Your Scene ID
- Create or edit your scene at storysplat.com
- Click "Upload" or "Update" to publish
- Find the Scene ID in the "Developer Export" section
- Copy and paste into your shortcode or block
Advanced Usage
Custom Styling
Add CSS to customize the viewer container:
.storysplat-viewer-container {
border-radius: 12px;
overflow: hidden;
box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}
JavaScript Integration
Access viewer instances for custom controls:
// Get viewer instance by container ID
const viewer = StorySplatWP.getViewer('storysplat-12345');
// Control playback
viewer.play();
viewer.pause();
viewer.nextWaypoint();
// Listen for events
document.getElementById('storysplat-12345').addEventListener('storysplat:ready', (e) => {
console.log('Viewer ready:', e.detail.viewer);
});
Multiple Viewers
You can embed multiple scenes on a single page:
Performance Tips
- Use Lazy Loading - Enable
lazyload="true"for below-the-fold content - Limit Per Page - Avoid too many 3D viewers on a single page
- Optimize Images - Use optimized thumbnails for lazy loading
Troubleshooting
Scene Not Loading
- Verify the scene ID is correct
- Ensure the scene is published and public on StorySplat
- Check browser console for errors
Blank Container
- Ensure the container has valid dimensions
- Check that JavaScript is enabled
- Verify no conflicting plugins
Performance Issues
- Enable lazy loading
- Reduce number of viewers per page
- Check device WebGL support
Support
- Plugin Issues: GitHub Issues
- Documentation: docs.storysplat.com
- Email: support@storysplat.com