Vol. 1 · The AI Prompt Library Free · No signup · Copy & paste

Prompt Library

For Copilot

Copilot Prompts

Prompts for both Copilots: Microsoft 365 Copilot inside Excel, Outlook, Word, PowerPoint and Teams, and GitHub Copilot in your editor. Each is copy-ready with an example of what it returns.

There are two Copilots, and good prompts look different for each. Microsoft 365 Copilot lives inside your Office apps, so the strongest prompts hand it a real artifact to work on — a table to analyze in Excel, a buried Outlook thread to summarize and reply to, rough bullets to turn into a Word draft, a document to shape into slides, or a Teams meeting you missed. GitHub Copilot lives in your editor, so its prompts target code you have selected: explain an unfamiliar function, generate tests that actually cover the edges, refactor without changing behavior, debug from a stack trace, or write the commit message from your diff.

Every prompt below names the exact output you want — a structure, a constraint, a guardrail against invented detail — because that is what separates a useful Copilot answer from a vague one. Copy any prompt, swap in your details, and for the GitHub ones, select your code first so Copilot Chat scopes the answer to what you highlighted.

10 prompts · free to copy · example output on each

Copilot

Analyze a table in Excel with Copilot

Ask Copilot in Excel to find trends and add a formula column — no formula syntax needed.

The prompt
I have a table on this sheet. Analyze it and help me act on it.

The data is: [DESCRIBE THE COLUMNS, e.g. "Column A date, B region, C revenue, D units"]
What I want to understand: [YOUR QUESTION, e.g. "which region is growing fastest and where revenue per unit is dropping"]

Do four things:
1. Summarize the top 3 trends in plain English, each with the number that supports it.
2. Add a new column that calculates [METRIC, e.g. "revenue per unit"] and explain the formula in one line.
3. Flag any rows that look like errors or outliers.
4. Suggest one chart that would show the main trend, and which columns to use.
Example output
Top trends: 1. West revenue grew 38% over the period (Q1 $412K → Q4 $568K) — the fastest of any region. 2. Revenue per unit fell 9% company-wide ($24.10 → $21.90), driven mostly by the East region's discounting. 3. Units sold rose 22% but revenue only 11% — volume is up, price realization is down. New column "Revenue per unit" → =C2/D2 (revenue divided by units, filled down the table). Outliers: Row 47 shows 0 units but $1,800 revenue — likely a data-entry error worth checking. Suggested chart: a line chart of Revenue per unit by month, split by region, to show where price erosion is happening.

TipIn Excel, format your range as a Table (Ctrl+T) first — Copilot is far more reliable at adding formula columns and reasoning about your data when it sits in a named table rather than a loose range.

Copilot

Summarize a long Outlook thread and draft a reply

Catch up on a buried email thread and respond in one step (Microsoft 365 Copilot in Outlook).

The prompt 2 fields to fill
Summarize this email thread and draft my reply.

Summary first: what was decided, what is still open, who is waiting on whom, and any dates mentioned — 5 bullets max.

Then draft a reply from me (, ) that: [WHAT MY REPLY NEEDS TO DO, e.g. "confirm the Thursday deadline and ask Marcus for the credentials"].

Keep the reply under 120 words, direct, no filler. Don't invent any facts that aren't in the thread.
Example output
Summary: - Decision: vendor onboarding starts the week of Jun 16 (confirmed by Sarah). - Open: Legal still hasn't signed the MSA — no date given. - Blocker: Marcus owes the API credentials; two people are waiting on him. - Deadline: pilot launch is locked for Jul 1. - Conflict: Sarah called the budget "final" on Jun 9; Tom said "pending finance" on Jun 11. Draft reply: Hi all — confirming we're on track for the Jul 1 pilot. Marcus, can you send the API credentials by end of day Thursday? That's the one item still blocking onboarding. Sarah, can you clarify the budget status so Tom and I are aligned before we kick off? Thanks, [MY NAME]

TipOpen the thread and use Copilot's "Summarize" button to ground it on the real message history, then refine with this prompt — it reads the actual emails, so you never have to paste anything in.

Copilot

Draft a Word document from rough bullets

Turn a messy outline into a structured first draft in Microsoft Word with Copilot.

The prompt 3 fields to fill
Draft a [DOCUMENT TYPE, e.g. "one-page project brief"] from the notes below.

Audience: 
Tone: [e.g. "plain, confident, no jargon"]
Length: about  words.

Structure it with clear headings. Where my notes are thin, leave a [bracketed placeholder] rather than inventing details. End with a short "Open questions" section listing anything I still need to decide.

My notes:
Example output
Project Brief: Billing Module Rollout Goal Ship the new billing module to all customers by Jul 1, with a two-week buffer for load testing. Scope - In: invoice generation, payment reconciliation, Stripe webhook handling. - Out: subscription upgrades (phase 2). Risks Data migration from two legacy databases with incompatible date formats. [Owner for migration cleanup — TBD.] Open questions - Soft-launch to 10% of accounts first, or full release on day one? - Will customer support be trained on billing queries by Jul 1?

TipGive Copilot a real target length and audience — "about 250 words for the exec team" produces a tighter draft than an open-ended "write a brief," which tends to pad.

Copilot

Build a PowerPoint deck from a document

Turn a Word doc or report into a structured slide outline with Copilot in PowerPoint.

The prompt 4 fields to fill
Create a presentation from .

Audience: 
Length:  slides, plus a title and a closing slide.
Goal of the talk: .

For each slide give me: a short headline, 3 bullet points max, and a one-line speaker note. Keep bullets to phrases, not sentences. Don't put more than one idea on a slide.
Example output
Slide 1 — Title: "Billing Module: Launch Plan & Risks" Slide 2 — Why now - Legacy system fails at scale - Support tickets up 30% - Revenue leakage on failed payments (Note: open with the cost of doing nothing.) Slide 3 — What ships Jul 1 - Invoice generation - Payment reconciliation - Stripe webhooks Slide 4 — The one real risk - Legacy date-format mismatch - Needs manual cleanup pre-import - One-week buffer built in Slide 5 — The ask - Approve the two-week timeline - Assign a migration owner today

TipPoint Copilot at a specific file by name ("create a presentation from Q3-Billing-Brief.docx") — it pulls the real structure and headings instead of guessing, which makes the outline match your source.

Copilot

Recap a Teams meeting you missed

Get decisions, action items and what you specifically missed from a Teams call (Copilot).

The prompt
I missed this meeting. Catch me up using the transcript and recording.

Give me:
1. A 3-sentence summary: topic, main decision, biggest open question.
2. Action items as a table — Owner | Task | Due (use "TBD" if no date was said).
3. Anything that was said about [MY NAME or MY TEAM, e.g. "the data team" or "the migration"] specifically.
4. One thing that was debated but not resolved.

Don't invent owners or dates that weren't mentioned.
Example output
Summary: The team reviewed the Q3 billing rollout and agreed to push the public launch two weeks for load testing. The open question is whether support will be ready for billing queries by the new date. Action items: Owner | Task | Due Priya | Load-test scenario list | Jun 20 Marcus | Confirm CS training schedule | Jun 18 Engineering | Fix invoice pagination bug | Jun 17 About the data team: Priya flagged that migration cleanup needs one engineer for ~3 days the week of Jun 16 — she asked your team to name who. Unresolved: soft-launch to 10% first vs. full release on day one.

TipCopilot in Teams only works on meetings that were recorded or transcribed — turn on transcription when you schedule the call, or you'll have nothing for it to recap afterward.

Copilot

Explain unfamiliar code (GitHub Copilot)

Use Copilot Chat /explain to understand a function before you touch it.

The prompt 1 field to fill
Explain the selected code to someone who knows basic syntax but not this codebase.

1. What it does, in one sentence.
2. A walk-through of each logical block and why it's there.
3. The one part a newcomer is most likely to misread.
4. Any side effects, edge cases, or failure modes.

Don't assume I know the framework — spell out non-obvious calls.

Code:
Example output
What it does: Fetches users from an API and returns only the active ones. Walk-through: - `async`/`await`: the function pauses at the network call instead of blocking the app. - `response.json()`: parses the HTTP body into a JS object — without it you have raw bytes. - `.filter(u => u.active)`: keeps only users whose `active` flag is true. Most-misread part: `await` doesn't time out on its own. If the server hangs and no timeout is set, the promise can wait indefinitely. Edge cases: if the response is an error status, `response.json()` may still parse an error object — check `response.ok` before trusting the data.

TipIn your IDE, select the code first, then type "/explain" in Copilot Chat — it scopes the answer to exactly what you highlighted instead of the whole file, so the walk-through stays on point.

Copilot

Generate unit tests (GitHub Copilot)

Ask Copilot Chat /tests to cover the happy path plus edge cases.

The prompt 1 field to fill
Write unit tests for the selected function using [TEST FRAMEWORK, e.g. "Jest" / "pytest" / "JUnit"].

Cover:
- The normal/happy path.
- Boundary cases (empty input, zero, max values).
- Invalid input and the error it should throw.
- One realistic edge case specific to what this function does.

Use clear test names that describe the behavior, not "test1". Add a one-line comment on any non-obvious assertion.

Function:
Example output
describe('calculateDiscount', () => { it('applies the percentage discount to a normal price', () => { expect(calculateDiscount(100, 20)).toBe(80); }); it('returns the original price when discount is 0', () => { expect(calculateDiscount(100, 0)).toBe(100); }); it('throws when the discount is over 100%', () => { expect(() => calculateDiscount(100, 120)).toThrow('Invalid discount'); }); it('rounds to 2 decimals to avoid floating-point drift', () => { // 19.99 * 0.1 would otherwise yield 1.7991000000000002 expect(calculateDiscount(19.99, 10)).toBe(17.99); }); });

TipAfter Copilot generates the tests, run them before trusting them — a generated test that passes against buggy code just locks in the bug. The boundary and error cases are where you'll catch real problems.

Copilot

Refactor a function (GitHub Copilot)

Get a cleaner version with the reasoning, not just a rewrite.

The prompt 1 field to fill
Refactor the selected function for readability and maintainability without changing its behavior.

Rules:
- Keep the same inputs, outputs, and side effects.
- Prefer clear names and early returns over deep nesting.
- Don't add a new dependency unless you explain why it's worth it.

Give me: the refactored code, then a short bullet list of what you changed and why. If you spot a likely bug while refactoring, flag it separately — don't silently "fix" it.

Code:
Example output
Refactored: function getActiveUserEmails(users) { if (!users?.length) return []; return users .filter(user => user.active) .map(user => user.email.toLowerCase()); } What changed: - Added an early return for null/empty input (was throwing on undefined). - Renamed `x` → `user` and `fn` → `getActiveUserEmails` for intent. - Replaced the manual for-loop + push with filter/map. Possible bug (flagging, not fixing): the original didn't lowercase emails, so duplicate detection downstream was case-sensitive. I normalized it — confirm that's the behavior you want before merging.

TipThe "flag bugs separately, don't silently fix" instruction matters: a refactor that quietly changes behavior is how a "cleanup" PR breaks production. You want the change surfaced so you can decide.

Copilot

Debug an error message (GitHub Copilot)

Paste the error and code into Copilot Chat /fix and get the cause, not just a patch.

The prompt 3 fields to fill
I'm getting this error. Help me fix it properly.

Error:


Relevant code:


What I was trying to do: 

Tell me: (1) the root cause in plain English, (2) the specific fix with the corrected code, (3) why it happened so I avoid it next time, and (4) one thing to check in case there's a deeper issue. Don't just suppress the error.
Example output
Root cause: You're calling `.map()` on `data` before the fetch resolves, so `data` is still `undefined` on first render. Fix: const [data, setData] = useState([]); // default to [] not undefined // ... {data.map(item => <Row key={item.id} item={item} />)} Why it happened: the component renders once before the async fetch finishes; `undefined.map` throws. Defaulting state to an empty array makes the first render safe. Deeper check: also handle the error and loading states — if the fetch fails, `data` stays `[]` silently. Add an `error` state so a failed request isn't indistinguishable from "no results."

TipAlways paste the full stack trace, not just the last line — Copilot uses the call chain to find where the bad value originated, which is usually a few frames above where the error actually surfaced.

Copilot

Write a commit message or PR description (GitHub Copilot)

Turn a diff into a clear conventional commit message and PR summary.

The prompt 1 field to fill
Write a commit message and a short PR description for the staged changes.

Commit message: use Conventional Commits (e.g. feat:, fix:, refactor:). One concise subject line under 72 characters, then a body explaining the "why," not the "what."

PR description: 2-3 sentences of what changed and why, a bullet list of the key changes, and a "How to test" line.

Don't restate the diff line by line — summarize intent. Context: .
Example output
Commit: fix: default user list to empty array to prevent render crash The component rendered before the fetch resolved, so `data.map` threw on undefined. Defaulting state to [] makes the first render safe and removes the white-screen error on slow connections. PR description: Fixes the intermittent crash on the Users page when the API is slow. The list now renders an empty state instead of throwing. - Default `data` state to `[]` instead of `undefined` - Add an explicit error state for failed requests How to test: throttle the network to "Slow 3G" and load /users — the page should show the empty state, then the list, with no console error.

TipUse Copilot's "Generate commit message" button in the Source Control panel for the subject line, then expand it with this prompt for the body and PR text — the diff is already in context, so you don't paste anything.

Frequently asked questions

What are the best Copilot prompts?

The ones that give Copilot something concrete to act on: a specific Excel table, a real Outlook thread, a selected function, or a stack trace — plus the exact structure you want back. This page collects those for both Microsoft 365 Copilot and GitHub Copilot, each with an example output.

Do these work for both Microsoft 365 Copilot and GitHub Copilot?

Yes — the set is split between them. The Excel, Outlook, Word, PowerPoint and Teams prompts are for Microsoft 365 Copilot; the explain, tests, refactor, fix and commit-message prompts are for GitHub Copilot Chat in your editor. Each card notes which Copilot it is for.

How do I get the best results from GitHub Copilot Chat?

Select the relevant code first, then run the prompt — Copilot scopes its answer to what you highlighted instead of guessing at the whole file. The slash commands /explain, /tests and /fix map directly to several prompts here, and pasting the full stack trace (not just the last line) helps it find the real cause.

Are these Copilot prompts free?

Yes — every prompt here is free to copy with no account, email, or paywall. You need access to Copilot itself (a Microsoft 365 Copilot license or a GitHub Copilot subscription), but the prompts cost nothing.