> ## Documentation Index
> Fetch the complete documentation index at: https://confidence.spotify.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Archive a Flag

> Learn how to archive a flag when it's no longer needed.

export const HowToSchema = ({name, description, steps = []}) => {
  const schema = {
    "@context": "https://schema.org",
    "@type": "HowTo",
    name,
    description
  };
  if (steps.length > 0) {
    schema.step = steps.map((s, i) => ({
      "@type": "HowToStep",
      position: i + 1,
      name: typeof s === "string" ? s : s.name,
      text: typeof s === "string" ? s : s.text || s.name
    }));
  }
  return <script type="application/ld+json" dangerouslySetInnerHTML={{
    __html: JSON.stringify(schema)
  }} />;
};

<HowToSchema
  name="Archive a Flag"
  description="Learn how to archive a flag when it's no longer needed."
  steps={[
"Go to Confidence, and select Flags on the left sidebar",
"Select the flag you want to archive",
"Click Archive in the Actions section on the right sidebar",
]}
/>

[Archiving a flag](../flags/create-flags#archiving-flags) prevents clients from resolving and using it.

## Archive a Flag

<Steps>
  <Step title="Go to Confidence, and select Flags on the left sidebar" />

  <Step title="Select the flag you want to archive" />

  <Step title="Click Archive in the Actions section on the right sidebar" />
</Steps>

<Note>
  You must disable or delete all active rules on a flag before you can archive it.
</Note>

## Related Resources

<CardGroup cols={2}>
  <Card title="Create a Flag" href="/docs/how-to-guides/create-flag">
    Set up a new feature flag
  </Card>

  <Card title="Flags Reference" href="/docs/flags/create-flags">
    Learn about flag lifecycle and archiving
  </Card>

  <Card title="Manage Clients" href="/docs/how-to-guides/manage-clients">
    Configure clients that resolve flags
  </Card>

  <Card title="Archive Flag API" href="/docs/api/how-to-guides/flags/archive-flag">
    API reference for archiving
  </Card>
</CardGroup>
