{"id":12732,"plugin_id":"plugins_6a8ddf314ab88191864c208fda197798","kind":"skill","collection_source":null,"comparison_source":null,"observed_at":"2026-09-30T23:02:05.971Z","digest":"08773912fe6e7a3f79051162f922b32b5240d1495a43596129c118af378f93bc","against":null,"payload":{"name":"firebase-remote-config-basics","description":"Manages Firebase Remote Config templates, feature flags, loading strategies, and SDKs (Android, iOS). Use when downloading/deploying remoteconfig JSON templates, managing version history/feature flags, setting in-app defaults, fetchAndActivate(), real-time listeners, or SDK setup. Don't use for Firebase Hosting, Auth, Firestore, Data Connect, Crashlytics, or App Hosting.","included_files":[{"relative_path":"references/android_setup.md","size_in_bytes":3484},{"relative_path":"references/ios_setup.md","size_in_bytes":2678}],"skill_md_contents":"---\nname: firebase-remote-config-basics\ndescription: >-\n  Manages Firebase Remote Config templates, feature flags, loading strategies, and SDKs (Android, iOS). Use when downloading/deploying remoteconfig JSON templates, managing version history/feature flags, setting in-app defaults, fetchAndActivate(), real-time listeners, or SDK setup. Don't use for Firebase Hosting, Auth, Firestore, Data Connect, Crashlytics, or App Hosting.\ncompatibility: This skill is best used with the Firebase CLI, but does not require it. Firebase CLI can be accessed through `npx -y firebase-tools@latest`.\nmetadata:\n  category: ApplicationDevelopment\n---\n\n# Remote Config\n\nThis skill provides a complete guide for getting started with Remote Config on\nAndroid or iOS. Remote Config allows you to change the behavior and appearance\nof your app without publishing an app update by maintaining a cloud-based\nconfiguration template.\n\n## Prerequisites\n\nProvisioning Remote Config requires both a Firebase project and a Firebase app,\neither Android or iOS. To manage the Remote Config template and conditions via\nthe command line, use the Firebase CLI. See the `firebase-basics` skill for\nreferences on project initialization.\n\n## Troubleshooting Execution\n\n### Handling npx 403 Forbidden Errors\n\nIf `npx -y firebase-tools@latest` fails due to registry permissions (403 error):\n\n1. **Inform the user**: \"I am unable to fetch the latest Firebase tools via npx\n   due to a registry error.\"\n1. **Fallback**: Attempt to use the local `firebase` command directly if the\n   user confirms it is installed globally (`npm install -g firebase-tools`).\n\n### Handling Project Context Issues\n\nIf a command fails because \"no active project is selected\":\n\n1. **Check login**: Run `npx -y firebase-tools@latest login:list`.\n1. **Prompt for ID**: If logged in but no project is active, ask the user:\n   \"Please provide your Firebase Project ID to proceed.\"\n1. **Use Flag**: Append `--project <PROJECT_ID>` to every subsequent command.\n\n## SDK Setup\n\nTo learn how to set up Remote Config in your application code, choose your\nplatform:\n\n- **Android**: [android_setup.md](references/android_setup.md)\n- **iOS**: [ios_setup.md](references/ios_setup.md)\n\n## Best Practices and Template Management\n\nFollow these guidelines and use the associated CLI tools to ensure efficient and\nsafe use of Remote Config.\n\n### Fetching Strategies\n\nTo optimize app performance and user experience, follow these recommended\npatterns (see\n[Loading Strategies](https://firebase.google.com/docs/remote-config/loading)):\n\n- **Load new values for next startup**: The most effective pattern is to\n  activate previously fetched values immediately on startup and fetch new values\n  in the background to be used next time. This minimizes user wait time.\n- **Real-time Updates**: Use the SDK's real-time listener to update the app\n  instantly without a refresh when server-side configuration changes.\n\n### Template Management via CLI\n\nUse the following commands to manage your Remote Config template and version\nhistory through the terminal:\n\n### Template Management via CLI\n\nUse the following commands to manage your Remote Config template and version\nhistory through the terminal:\n\n- **Get current template**: Save the remote template to a local JSON file for\n  auditing or modification.\n\n  ```bash\n  npx -y firebase-tools@latest remoteconfig:get -o remote_config.json\n  ```\n\n- **Autonomous Editing & Discovery** : Modify the local `remote_config.json`\n  directly. Determine the correct signal (e.g., device.country or percent) and\n  update the \"conditions\" array and \"parameters\" map accordingly.\n\n- **MANDATORY: User Review and Verification** : STOP and ask the user to verify\n  your changes before proceeding to deployment.\n\n  - Action: Inform the user: \"I have prepared the changes in remote_config.json.\n    Please review the file for accuracy. Once you are satisfied, tell me to\n    'deploy' to make the changes live.\"\n\n- **Deployment Orchestration** : To push changes, you must ensure the\n  environment is configured for deployment.\n\n  - Config Mapping: If a firebase.json file is missing, create one to map the\n    local JSON to the Remote Config service:\n\n  ```json\n    { \"remoteconfig\": { \"template\": \"remote_config.json\" } }\n  ```\n\n  - Deploy: Execute the partial deployment command\n    \n    ```bash\n    npx -y firebase-tools@latest deploy --only remoteconfig\n    ```\n\n- **Verification**: After deployment, verify the update by listing the version\n  history.\n\n  ```bash\n  npx -y firebase-tools@latest remoteconfig:versions:list\n  ```\n\nThe SDK provides a number of features to make your application dynamic and\nresponsive to user segments.\n\n- **Set In-App Defaults**: Define baseline values to ensure the app functions\n  offline or before the first fetch.\n- **Fetch and Activate**: Retrieve values from the Firebase backend and apply\n  them to the local UI/Logic.\n- **Template Management**: Use the Firebase CLI to version-control, get, and\n  deploy your config JSON files.\n"},"changes":[],"summary":"First saved snapshot. No earlier version is available for comparison.","summary_kind":"deterministic","summary_metadata":{}}