{"id":26517052,"url":"https://github.com/altersquare/preferred-google-login","last_synced_at":"2026-05-09T13:04:58.054Z","repository":{"id":278892065,"uuid":"937095583","full_name":"altersquare/preferred-google-login","owner":"altersquare","description":"This Chrome extension simplifies switching between multiple Google accounts by automatically adding the authuser parameter to relevant Google domains.","archived":false,"fork":false,"pushed_at":"2025-03-18T05:52:09.000Z","size":284,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-18T06:33:56.543Z","etag":null,"topics":["browser","browser-extension","chrome","chrome-extension","google"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/altersquare.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-02-22T10:22:45.000Z","updated_at":"2025-03-18T05:52:13.000Z","dependencies_parsed_at":"2025-02-22T11:25:25.606Z","dependency_job_id":"93b046c4-8af2-4012-94f9-bd178230979e","html_url":"https://github.com/altersquare/preferred-google-login","commit_stats":null,"previous_names":["rohandhamapurkar/default-google-account-extension","altersquareio/default-google-account-extension","altersquareio/preferred-google-login","altersquare/preferred-google-login"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/altersquare%2Fpreferred-google-login","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/altersquare%2Fpreferred-google-login/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/altersquare%2Fpreferred-google-login/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/altersquare%2Fpreferred-google-login/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/altersquare","download_url":"https://codeload.github.com/altersquare/preferred-google-login/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244759961,"owners_count":20505716,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["browser","browser-extension","chrome","chrome-extension","google"],"created_at":"2025-03-21T08:17:53.842Z","updated_at":"2026-05-09T13:04:58.008Z","avatar_url":"https://github.com/altersquare.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Preferred Google Login\n\nA Chrome extension that automatically adds the `authuser` parameter to Google domains, allowing you to set your preferred Google account for each service.\n\n## Overview\n\nIf you use multiple Google accounts (personal, work, school), you know the frustration of constantly being logged into the wrong account when visiting different Google services. This extension solves that problem by automatically adding the appropriate `authuser` parameter to URLs based on the domain, ensuring you're always using your preferred account for each Google service.\n\n## Features\n\n- **Domain-Specific Account Selection**: Set different preferred accounts for different Google domains (e.g., YouTube, Gmail, Drive)\n- **Auto-Redirect**: Automatically redirects to add the `authuser` parameter when you visit a configured Google domain\n- **Smart Loop Prevention**: Intelligently prevents redirect loops\n- **Google Domain Autocomplete**: Includes autocomplete suggestions for popular Google domains\n- **User-Friendly Interface**: Clean, modern UI with toggle to quickly enable/disable the extension\n- **Multiple Account Support**: Easily manage multiple Google accounts across different services\n- **Privacy-Focused**: No data collection, all settings stored locally in your browser\n\n## Installation\n\n### Manual Installation (Developer Mode)\n1. Download or clone this repository:\n   ```bash\n   git clone https://github.com/altersquareio/preferred-google-login.git\n   ```\n2. Open Chrome and navigate to `chrome://extensions/`\n3. Enable \"Developer mode\" in the top-right corner\n4. Click \"Load unpacked\" and select the directory containing the extension files\n\n## Usage\n\n1. Click the extension icon in your browser toolbar\n2. Toggle the extension on/off using the switch in the header\n3. Add domain and email pairs:\n   - Click \"Add Domain\" to create a new entry\n   - Enter a Google domain (or select from autocomplete suggestions)\n   - Enter the Gmail address you prefer to use for that domain\n4. Click \"Save Changes\" to apply your settings\n5. Visit any Google service - the extension will automatically redirect you to use your preferred account\n\n## Domain Configuration Examples\n\n| Domain | Email | Result |\n|--------|-------|--------|\n| youtube.com | work@gmail.com | YouTube always uses your work account |\n| mail.google.com | personal@gmail.com | Gmail always opens with your personal account |\n| drive.google.com | school@gmail.com | Google Drive defaults to your school account |\n\n## Supported Google Domains\n\nThe extension supports numerous Google domains, including:\n- google.com\n- youtube.com\n- mail.google.com\n- drive.google.com\n- docs.google.com\n- cloud.google.com\n- meet.google.com\n- photos.google.com\n- gemini.google.com\n- classroom.google.com\n- and many more!\n\n## How It Works\n\nThe extension:\n1. Checks if the current website is a Google domain\n2. Determines if you've configured a preferred account for that domain\n3. Adds the appropriate `authuser` parameter to the URL\n4. Implements safeguards to prevent redirect loops\n5. Provides an intuitive UI for managing your preferences\n\n## Technical Details\n\n- Built with vanilla JavaScript, HTML, and CSS\n- Uses Chrome's Storage API for persistent settings\n- Content script runs at document start to ensure timely redirects\n- Modern ES6+ JavaScript features for clean, maintainable code\n- Responsive UI design that works across different screen sizes\n- Code formatting with Prettier and linting with ESLint\n\n## Privacy\n\nThis extension:\n- Does NOT collect any user data\n- Does NOT send any information to external servers\n- Stores your domain-email preferences only in your browser's local storage\n- Requires minimal permissions (only storage and scripting)\n\n## Contributing\n\nContributions are welcome! To contribute:\n\n1. Fork the repository\n2. Create a feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -m 'Add some amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n## Development\n\n### Project Structure\n\n```\n├── .vscode            # VS Code configuration\n├── icons              # Extension icons in various sizes\n├── src                # Source code\n│   ├── content.js     # Content script for adding authuser parameter\n│   ├── popup.html     # Extension popup interface\n│   └── popup.js       # Popup functionality\n├── .gitignore         # Git ignore file\n├── .prettierrc.js     # Prettier configuration\n├── eslint.config.mjs  # ESLint configuration\n├── LICENSE            # MIT License\n├── manifest.json      # Chrome extension manifest\n├── package.json       # NPM package configuration\n└── README.md          # This file\n```\n\n### Getting Started\n\n```bash\n# Install dependencies\nnpm install\n\n# Run lint checks\nnpm run lint\n\n# Format code\nnpm run format\n```\n\n## License\n\n```\nMIT License\n\nCopyright (c) 2025 Rohan Dhamapurkar\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n```\n\n## Contact\n\nRohan Dhamapurkar - dhamapurkar54@gmail.com  \nProject: [https://github.com/altersquareio/preferred-google-login](https://github.com/altersquareio/preferred-google-login)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faltersquare%2Fpreferred-google-login","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faltersquare%2Fpreferred-google-login","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faltersquare%2Fpreferred-google-login/lists"}