パスワード生成器

長さとオプションを指定して安全なランダムパスワードを生成します。

// about

ツールについて

ハッカーに推測されにくい強力で安全なパスワードを作成します。長さや英大文字・小文字、数字、記号の組み合わせを自由に変更できます。

使い方

  1. パスワードの長さを指定します(12文字以上推奨)。
  2. 大文字・小文字・数字・記号のチェックボックスを選びます。
  3. 「生成」を押して作成されたパスワードをコピーします。

このツールが使われる理由

  • 一瞬で安全性の高いパスワードを作成できます。
  • 文字数や使用する文字の種類を自由にカスタマイズ可能です。
  • 作成したパスワードは一切保存・送信されないため安心です。

よくある質問 (FAQ)

どのようなパスワードが安全ですか?

12文字以上で、英大文字・小文字・数字・記号がバランスよく混ざっているものです。

生成されたパスワードはどこかに保存されますか?

いいえ。処理はすべてブラウザ内で行われ、サーバーには保存されません。

パスワードはどのくらいの頻度で変更すべきですか?

重要なアカウントのパスワードは数ヶ月ごとに変更することをおすすめします。

ガイド · セキュリティ · 4分で読めます

強いパスワードの作り方:長さ、エントロピー、パスワードマネージャー

「記号を1つ以上含める」といったルールはおなじみですが、パスワードを本当に強くするのはランダムさと長さです。計算してみると、なぜ弱いパスワードがあるのかがはっきり分かります。

攻撃者が使う主な方法は3つです。他のサイトから流出したユーザー名とパスワードを使い回すクレデンシャルスタッフィング、よく使われるパスワードや単語を試す辞書攻撃、そしてあらゆる組み合わせを試す総当たり攻撃です。

数字6桁                       : 6 × log2(10)  ≈ 20ビット
ランダムな小文字16文字        : 16 × log2(26) ≈ 75ビット
94種からランダムに12文字      : 12 × log2(94) ≈ 79ビット
ランダムな英数字16文字        : 16 × log2(62) ≈ 95ビット
パスワードのエントロピーの計算方法、複雑さのルールより長さが効く理由、避けるべきパターン、パスワードマネージャーの使い方を解説します。
ガイドを読む →
AIで作る

このツールをAIで自作してみましょう

自分用のバージョンが必要なら、作業指示プロンプトをAIチャットに貼り付けるか、スキルファイルをAIコーディングエージェントに保存してください。私たちが開発時に整理した機能、例外、テストケースが含まれています。

プロンプトとスキルは英語で提供しています。AIツールはどの言語でもよく理解できます。

AI作業指示プロンプト

Claude、ChatGPT、GeminiなどのAIチャットにそのまま貼り付けてください。

You are an experienced full-stack web developer. Build a web tool called "パスワード生成器" that meets the requirements below.

## Goal

Build a random password generator that uses a cryptographically secure random source.

## Core features

- Length from 8 to 128
- Toggle upper case, lower case, digits and symbols
- Option to exclude look-alike characters (0/O, l/1)
- Generate several at once
- Show entropy in bits and a strength label

## Inputs

- Length, character sets, count, exclusions

## Outputs

- List of passwords
- Estimated entropy in bits

## Edge cases and handling rules

- Explain that at least one character set is required
- Guarantee at least one character from each selected set
- Use crypto.getRandomValues, never Math.random
- Avoid modulo bias when picking characters

## Implementation requirements

- Build it as a single page (HTML, CSS, JavaScript) that runs entirely in the browser, and never send the user's input to a server.
- Make the UI responsive and easy to use on mobile; label every input and keep everything keyboard accessible.
- Add a Copy button for results and show clear, friendly error messages for invalid input.
- Keep the core logic in functions separate from the UI so it can be unit-tested.

## Definition of done (test cases)

- Every result has 16 characters when length is 16
- Only digits appear when only digits are selected
- 12 characters from 94 shows about 79 bits

First outline your implementation plan in at most five lines, then write the complete code, and finally explain how to check the test cases above.

スキル (SKILL.md)

Claude CodeなどのAIコーディングエージェントで .claude/skills/build-password-generator/SKILL.md に保存すると、このツールを作る・直すたびに再利用できます。

---
name: build-password-generator
description: Use when building or changing a パスワード生成器 tool. Build a random password generator that uses a cryptographically secure random source.
---

# Build: パスワード生成器

## Goal

Build a random password generator that uses a cryptographically secure random source.

## Workflow

1. Review the required features, inputs and outputs below and ask about anything missing first.
2. Implement the core logic as pure functions separate from the UI.
3. Check the logic against the test cases in the verification list.
4. Build a responsive UI with an input form, a result area and a Copy button.
5. Reproduce each edge case listed under Rules and refine the error messages.

## Core features

- Length from 8 to 128
- Toggle upper case, lower case, digits and symbols
- Option to exclude look-alike characters (0/O, l/1)
- Generate several at once
- Show entropy in bits and a strength label

## Inputs

- Length, character sets, count, exclusions

## Outputs

- List of passwords
- Estimated entropy in bits

## Rules

- Explain that at least one character set is required
- Guarantee at least one character from each selected set
- Use crypto.getRandomValues, never Math.random
- Avoid modulo bias when picking characters
- Build it as a single page (HTML, CSS, JavaScript) that runs entirely in the browser, and never send the user's input to a server.

## Verification

- [ ] Every result has 16 characters when length is 16
- [ ] Only digits appear when only digits are selected
- [ ] 12 characters from 94 shows about 79 bits

AIに任せるときのコツ

  • 最初の行に使用技術(React、Vue、素のHTMLなど)を書くと、プロジェクトに合ったコードになります。
  • コードを受け取る前に、テストケースを実行して結果を見せるよう依頼しましょう。
  • 本物のパスワード、顧客データ、APIキーは入力せず、サンプル値を使ってください。