Write a Great User Story

Print this topicEmail this topic

What is a user story?

A user story represents a small piece of business value that a team can deliver in an iteration. While traditional requirements (like use cases) try to be as detailed as possible, a user story is defined incrementally, in three stages:

  • The brief description of the need
  • The conversations that happen during backlog grooming and iteration planning to nail down the details
  • The tests that confirm the story's satisfactory completion

Well-formed stories will meet the criteria of Bill Wake's INVEST acronym:

Independent We want to be able to develop in any sequence.
Negotiable Avoid too much detail; keep them flexible so the team can adjust how much of the story to implement.
Valuable Users or customers get some value from the story.
Estimatable The team must be able to use them for planning.
Small Large stories are harder to estimate and plan. By the time of iteration planning, the story should be able to be designed, coded, and tested within the iteration.
Testable Document acceptance criteria, or the definition of done for the story, which lead to test cases.

Why use user stories?

  • Keep yourself expressing business value
  • Avoid introducing detail too early that would prevent design options and inappropriately lock developers into one solution
  • Avoid the appearance of false completeness and clarity
  • Get to small enough chunks that invite negotiation and movement in the backlog
  • Leave the technical functions to the architect, developers, testers, etc.

How do I write user stories?

When you're getting started with stories, a template can help ensure that you don't inadvertently start writing technical tasks:

As a <user type>, I want to <function> so that <benefit> .

Examples:

  • As a delivery team member, I want to know which tasks I own so that I can decide what to work on now.
  • As a developer, I want to know which of my stories have failing test cases so that I can fix the code.
  • As a product owner, I want to be able to drag-and-drop prioritize all the product backlog items, so that I can easily adjust priorities based on changing needs.

Try to avoid the generic role "User" when writing user stories. User stories are about all of the "actors" who interact with the system or who realize some value or benefit from the system. Not all actors are end users. For example, an actor could be another system or someone who wants certain functionality in order to buy your product but will never actually use the product. It may be useful to create aggregate actors (e.g. "consumer") and specialized actors (e.g. "browser" or "frequent shopper").

In Rally, this template should be entered at the top of the Description field. This sets the tone for the details and acceptance criteria, which will be entered below.

What size should a user story be?

A story should be small enough to be coded and tested within an iteration- ideally just a few days. When a story is too large, it is called an "epic". Backlog items tend to start as epics, when they are lower priority. For release planning, epics should be broken down into smaller chunks, but not so small that you've moved into detailed design.

How detailed should a user story be?

Too broad

  • "A team member can view iteration status."

Too detailed

  • "A team member can view a table of stories with rank, name, size, package, owner, and status."
  • "A team member can click a red button to expand the table to include detail, which lists all the tasks, with rank, name, estimate, owner, status."

Just right

  • "A team member can view the iteration's stories and their status, with main fields."
  • "A team member can view the current burndown chart on the status page, and can click it for a larger view."
  • "A team member can view or hide the tasks under the stories."
  • "A team member can edit a task from the iteration status page."

When do I add detail?

Acceptance criteria provide the 'Definition of Done' for the story. As details about the story evolve, capture the critical ones as acceptance criteria. The product owner should list as many acceptance criteria as possible in order to clarify the intent of the story. Regardless of how detailed the acceptance criteria are, the team should have a conversation about them and adjust the acceptance criteria to capture the results of the discussion. Once an iteration has begun, testers can formalize acceptance criteria into acceptance tests.

In Rally, place the acceptance criteria directly beneath the value statement in the Description field. Delivery team members have a single location to see all of the story info with this method. Tip: by using bullet points, you can keep each criteria item brief and clear.

Who uses user stories?

Creation — The customer, customer proxy, product owner and anyone else who identifies a need for the product can contribute user stories.
Ownership & Maintenance — The product owner owns the user stories and is responsible for writing, gathering, maintaining, and prioritizing.
Usage — Developers, testers, technical writers use user stories to be able to know what to implement and when they're done. Product owners track overall progress based on the status of the user stories. Management tends to track user stories rolled up to epics or features.

What are the top 3 mistakes that people make?

  1. Too formal / too much detail. Product owners with good intentions often try to write extremely detailed user stories.  If a team sees a story at iteration planning that looks like an IEEE requirements document, they'll often assume that all the details are there and they'll skip the detailed conversation.
  2. Technical tasks masquerading as stories. A lot of the power of Agile comes from having a working increment of software at the end of each iteration.  If your stories are really just technical tasks, you often don't end up with working software at the end of each iteration, and you lose flexibility in prioritization.
  3. Skipping the conversation. Stories are intentionally vague before iteration planning.  If you skip the acceptance criteria conversation, you'll risk moving in the wrong direction, missing edge cases or overlooking customer needs.

Example

Below is a sample user story in Rally. This story has been discussed by the team in several grooming and planning meetings as it moved up the backlog, and is close to being scheduled into an upcoming iteration. The purpose of this user story is to provide purchasers on an online site the ability to use a credit card for payment.

Feedback

Please send us your feedback regarding our help site. For feedback regarding the Rally product, click here to open a support case or click here to submit a new feature request
English
By submitting this form, you accept the Mollom privacy policy.
© 2014 Rally Software Development Corp | Legal