Helicobacter pylori
Helicobacter pylori colonizes the stomachs of more than half of the worlds population, and the infection continues to play a key role in the pathogenesis of a number of gastroduodenal diseases. Colonization of the gastric mucosa with Helicobacter pylori results in the development of chronic gastritis in infected individuals and, in a subset of patients, chronic gastritis progresses to complications (e.g., ulcer disease, stomach cancers, and some distinct extragastric disorders). However, more than 80% of individuals infected with the bacterium are asymptomatic and it has been postulated that it may play an important role in the natural stomach ecology. Critical illness
Gastritis may also develop after major surgery or traumatic injury ("Cushing ulcer"), burns ("Curling ulcer"), or severe infections. Gastritis may also occur in those who have had weight loss surgery resulting in the banding or reconstruction of the digestive tract. Diet
Evidence does not support a role for specific foods, including spicy foods and coffee, in the development of peptic ulcers. People are usually advised to avoid foods that bother them. There is little specific advice on diet published by authoritative sources. The website of the National Health Service of the United Kingdom advises "avoiding foods that can irritate the stomach, such as spicy, acidic or fried foods", and suggests that "you may want to talk to a GP about this". Pathophysiology
Acute
Acute erosive gastritis typically involves discrete foci of surface necrosis due to damage to mucosal defenses.
Since 1992, chronic gastritis lesions are classified according to the Sydney system. Metaplasia
Mucous gland metaplasia, the reversible replacement of differentiated cells, occurs in the setting of severe damage of the gastric glands, which then waste away (atrophic gastritis) and are progressively replaced by mucous glands. Gastric ulcers may develop; it is unclear if they are the causes or the consequences. Intestinal metaplasia typically begins in response to chronic mucosal injury in the antrum and may extend to the body. Gastric mucosa cells change to resemble intestinal mucosa and may even assume absorptive characteristics. Intestinal metaplasia is classified histologically as complete or incomplete. With complete metaplasia, gastric mucosa is completely transformed into small-bowel mucosa, both histologically and functionally, with the ability to absorb nutrients and secrete peptides. In incomplete metaplasia, the epithelium assumes a histologic appearance closer to that of the large intestine and frequently exhibits dysplasia. Diagnosis
Often, a diagnosis can be made based on  patients description of their symptoms. Other methods which may be used to verify gastritis include:

Blood tests:
Blood cell count
Presence of H. pylori
Liver, kidney, gallbladder, or pancreas functions
Urinalysis
Stool sample, to look for blood in the stool
X-rays
Endoscopy, to check for stomach lining inflammation and mucous erosion
Stomach biopsy, to test for gastritis and other conditionsThe OLGA staging frame of chronic gastritis on histopathology. Atrophy is scored as the percentage of atrophic glands and scored on a four-tiered scale. No atrophy (0%) = score 0; mild atrophy (1–30%) = score 1; moderate atrophy (31–60%) = score 2; 9 severe atrophy (>60%) = score 3.