Skip to content

Social links

Social links live in siteConfig.social in src/config/site.ts. The footer, the contact section, and any “follow us” block all read from the same object.

src/config/site.ts
social: {
twitter: "https://x.com/yourhandle",
github: "https://github.com/yourrepo",
linkedin: "https://linkedin.com/company/yourco",
// instagram: null,
// youtube: null,
// facebook: null,
} as Record<string, string | null | undefined>,

Each key is the platform name, each value is the full URL to your profile or page.

These are the keys the icon components in every theme already know how to render:

KeyIconTypical URL
twitterX / Twitter logohttps://x.com/yourhandle
githubGitHub logohttps://github.com/yourorg
linkedinLinkedIn logohttps://linkedin.com/company/yourco
instagramInstagram glyphhttps://instagram.com/yourhandle
youtubeYouTube logohttps://youtube.com/@yourchannel
facebookFacebook logohttps://facebook.com/yourpage
dribbbleDribbble dothttps://dribbble.com/yourhandle
mastodonMastodon logohttps://hachyderm.io/@yourhandle
blueskyBluesky butterflyhttps://bsky.app/profile/you.bsky.social

Not every theme ships every icon — open src/components/Icon.astro (or your theme’s Footer.astro) to confirm. Adding a new icon is a 10-line change; see Add a custom icon below.

Two ways, both work:

social: {
twitter: "https://x.com/yourhandle",
github: "https://github.com/yourrepo",
linkedin: null, // hidden — preferred
// facebook, // hidden — also fine
}

Components iterate Object.entries(social) and skip values that are null / undefined / empty string. Easier to scan a config that lists every supported platform with some set to null.

Some themes also ship src/config/social.json:

src/config/social.json
{
"twitter": "https://x.com/yourhandle",
"github": "https://github.com/yourrepo",
"linkedin": "https://linkedin.com/company/yourco"
}

Same shape as siteConfig.social. If your theme imports the JSON file (check src/components/Footer.astro), edit that. Otherwise edit site.ts.

If your platform isn’t in the list above:

  1. Find a 24×24 SVG of the logo. The brand’s official press kit usually has one.

  2. Open src/components/Icon.astro and add a new case to the switch (or to the icons object — depends on the theme):

    src/components/Icon.astro
    {name === "discord" && (
    <svg width={size} height={size} viewBox="0 0 24 24" fill="currentColor">
    <path d="M…"/>
    </svg>
    )}
  3. Add the new key to siteConfig.social:

    social: {
    // …
    discord: "https://discord.gg/yourinvite",
    }

The footer will pick it up on the next save.