Skip to main content

Overview

LiveCodes makes it easy to share your projects with others through:
  • Direct URLs - Share full or short URLs
  • QR Codes - Generate scannable QR codes
  • Social Media - Share to Facebook, Twitter, Reddit, and more
  • Permanent URLs - Save projects with permanent links

Share Methods

Quick Share

1

Open Share Menu

Click the Share button in the toolbar or go to MenuShare
2

Copy URL

Click the URL to copy it to your clipboard
3

Share

Paste the URL anywhere - email, chat, social media
Shared URLs include your entire project configuration compressed in the URL hash.

URL Types

Generates a shortened, user-friendly URL:
https://livecodes.io/?x=abc123
Short URLs expire after 1 year of inactivity. Perfect for quick sharing.

QR Codes

Generate QR codes for easy mobile sharing:
1

Generate QR Code

In the Share dialog, click “Show QR Code”
2

Scan & Share

Scan with any QR code reader or camera app
3

Save Image

Right-click to save the QR code image
QR codes automatically use short URLs for better scannability.

Social Sharing

Share directly to popular platforms:

Facebook

Share to your Facebook timeline

Twitter / X

Tweet your project with title and URL

Reddit

Submit to a subreddit

LinkedIn

Share on your professional network

Hacker News

Submit to Hacker News

Dev.to

Create a Dev.to post with your code
Also supported:
  • Pinterest
  • Tumblr
  • Email
  • Native share (on mobile devices)

Social Share Template

When sharing to social platforms, LiveCodes automatically:
  1. Uses your project title
  2. Generates a short URL
  3. Includes relevant hashtags (optional)
  4. Opens the platform’s share dialog
"My awesome LiveCodes project"
https://livecodes.io/?x=abc123
#livecodes #webdev

Share Options

What Gets Shared

Shared URLs include:
  • All your code (markup, style, script)
  • Language selections
  • External resources (scripts, stylesheets)
  • Editor settings
  • Project title and description
  • Custom types and imports
Shared URLs are public. Don’t include sensitive data like API keys or passwords.

Privacy Considerations

  • Client-side only: Your code is compressed and stored in the URL or browser storage
  • No server storage: Full URLs don’t store data on LiveCodes servers
  • Short URLs: Temporarily stored (1 year) for URL shortening
  • Permanent URLs: Stored indefinitely in browser-based storage

Advanced Sharing

Embed URLs

Share as an embedded playground:
<iframe 
  src="https://livecodes.io/?x=abc123&embed=true"
  style="width: 100%; height: 500px; border: 0;"
></iframe>
See Embed for more options.

Query Parameters

Customize shared URLs with parameters:
https://livecodes.io/?x=abc123&activeEditor=script&console=full
Common parameters:
  • activeEditor - Which editor to show (markup/style/script)
  • readonly - Make the playground read-only
  • console - Show console (none/open/full)
  • theme - Light or dark theme

Programmatic Sharing

Generate share URLs via SDK:
import { createPlayground } from 'livecodes';

const playground = await createPlayground('#container');

// Get shareable URL
const config = await playground.getConfig();
const shareUrl = await playground.getShareUrl(config);

console.log(shareUrl); // https://livecodes.io/?x=...

Best Practices

1

Add Title & Description

Set a meaningful title and description for your project
2

Choose URL Type

  • Short URLs for temporary sharing
  • Full URLs for permanence
  • Permanent URLs for important projects
3

Test Before Sharing

Open the share URL in an incognito window to verify it works
Add a comment at the top of your code explaining what the project does.

Share URL Expiration

URL TypeExpiresStorage
Full URLNeverIn URL hash
Short URL1 year (inactive)Server cache
Permanent URLNeverBrowser storage

Mobile Sharing

On mobile devices, LiveCodes uses the native Web Share API when available:
if (navigator.share) {
  await navigator.share({
    title: 'My Project',
    url: 'https://livecodes.io/?x=abc123'
  });
}
This opens your device’s native share sheet with all available apps.

Build docs developers (and LLMs) love