You might think that "mystery writing" and "crime writing" are different terms used to describe the same type of novel, but technically there is a crucial difference...
I will treat crime and mystery fiction separately here, but just be aware that these novels are often grouped together and called either "Mysteries" or "Crime Novels" (or something similar) by bookshops and publishers.
However these types of novels are collectively labeled, they represent one of the most popular genres of fiction and have a huge established readership.
Mystery novels revolve around the investigation of a crime, almost always murder, by some form of detective. The body tends to be discovered very close to the beginning of the novel, and the bulk of the action then concerns the detective's attempts to discover the identity of the murderer.
There will be several twists and turns along the way, usually in the form of more murders, but the detective will solve the mystery eventually and bring the guilty to justice.
The key point to remember is that mystery novels are precisely that: a mystery (or a puzzle, if you like) and fans of this type of fiction delight in trying to solve the puzzle before the detective does.
It is the mystery novelist's responsibility, therefore, to play fair with his or her audience, and this means providing clues (cleverly hidden ones, of course) for the reader to discover along the way.
I said above that the crime in this type of novel is usually murder, though mystery novels in the broadest sense can actually involve any type of puzzle: a missing person, theft, anything you like.
I also said that the crime is investigated by some form of detective - meaning they don't have to be a detective in the traditional sense. A child's disappearance, for example, could be investigated by the parents (with the police operating ineptly in the background).
As a matter of fact, it is the variety of detective used which often differentiates one sub-genre of mystery writing from the next. Here are some of the possibilities...
Professional Policeman/Policewoman. In other words, a high-ranking police officer who is officially assigned to the case. They usually have a lower-ranking officer to help them in their investigation (known as a "sidekick") but the majority of the police team investigating the crime will remain more or less in the background. Ruth Rendell's Wexford novels are a good example of mystery writing involving a professional detective.
Police Team. Mystery novels involving an entire police team's efforts to solve a crime, as opposed to just the principal detective's efforts, are known as "police procedurals." This is the most realistic form of detection a mystery novel can employ (because it's how crimes are investigated in the real world). Due to their emphasis on action, these types of novels are sometimes classified as thrillers. The books of Ed McBain are good examples.
(On a practical note, writing a police procedural means that, instead of having one protagonist - the detective - you will have several. This means that you will be writing a multiple viewpoint novel - which isn't a problem, but does make the handling of viewpoint more complex. Just something to bear in mind.)
Private Investigator. Not a professional cop, but an investigator for hire. This variety of mystery writing frequently begins with the private eye being hired to investigate a lesser crime than murder - a case involving a cheating spouse, for example. But dead bodies invariably start piling up along the way. These novels also tend to concentrate less on the "puzzle" element and more on action and gritty realism. The classic private eye is the hard-boiled Philip Marlowe, cynical and tough but romantic underneath. For more recent examples look to Sue Grafton or Sara Paretsky.
Amateur Sleuth. These detectives are frequently a local citizen with a personal interest in the investigation. Agatha Christie's Miss Marple is the perfect example. Although this sub-genre of mystery fiction is out of fashion now, there is nothing to stop you bringing it up to date with a little imagination.
Professional Sleuth. Not a professional policeman or woman, but a professional in the arena in which the murder (or other variety of crime) occurs. In Dick Francis's novels set in the world of horse racing, for example, the "investigators" are often jockeys or trainers or the like, and they make full use of their insider knowledge to solve the mystery.
Doctors and Lawyers. Such professionals are frequently used as detectives in mystery writing (think of Quincy on TV solving mysteries with his medical knowledge, or the lawyer Perry Mason). And you are not confined to doctors and lawyers, of course. How about a psychic as a detective? Or an archaeologist investigating ancient crimes? Whatever your own professional expertise may be, consider using it as a basis for a mystery novel.
So far we have looked at the variety of detective used as the key element which separates one sub-genre of mystery writing from another. Another of these elements is the setting used.
If your detective is a doctor or a lawyer, you will obviously employ a medical or legal setting. If your detective is Miss Marple (or a modern version of her), you might well choose a sleepy English village as your novel's background.
And setting doesn't just mean profession or place. For example, you can define your novels equally well by setting them in the past: Victorian London or Ancient Rome or Medieval France perhaps.
If the setting you choose is distinctive enough, and if no writer has used it before, and if it would work as the backdrop for a whole series of novels, you could well carve out a sub-genre of mystery writing all of your own!
The final thing to say about mystery writing is that your novel, if successful, will almost certainly become a series of novels (because that's what readers like).
Now, that's great news for your career (and for your bank account).
But given that you might have to live with your detective for years or even decades, make double-sure at this early stage that you create a protagonist you enjoy hanging out with.
If mystery novels focus on the detection of crime, crime novels focus on the criminals themselves as they perpetrate a crime.
Traditionally, it is the police who are the "goodies" and the criminals who are the "baddies", but all that is turned on its head in crime writing (in this strict definition of the term). Although we, as readers, don't altogether sympathize with the criminals' plans, we nevertheless find ourselves rooting for them.
The crime can be murder here, or any criminal activity that you choose, though typically it involves a bank heist. Mafia novels are also crime novels, with Mario Puzo's The Godfather being the most famous example.
Crime novels can have...
Next Step: If crime or mystery writing isn't your thing, you might want to consider Writing Suspense Novels or Thrillers...