Excluding medical illnesses associated with psychosis is performed by using blood tests to measure:

Thyroid-stimulating hormone to exclude hypo- or hyperthyroidism,
Basic electrolytes and serum calcium to rule out a metabolic disturbance,
Full blood count including ESR to rule out a systemic infection or chronic disease, and
Serology to exclude syphilis or HIV infection.Other investigations include:

EEG to exclude epilepsy, and an
MRI or CT scan of the head to exclude brain lesions.Because psychosis may be precipitated or exacerbated by common classes of medications, medication-induced psychosis should be ruled out, particularly for first-episode psychosis. Both substance- and medication-induced psychosis can be excluded to a high level of certainty, using toxicology screening. Because some dietary supplements may also induce psychosis or mania, but cannot be ruled out with laboratory tests, a psychotic individuals family, partner, or friends should be asked whether the patient is currently taking any dietary supplements.Common mistakes made when diagnosing people who are psychotic include:
Not properly excluding delirium,
Not appreciating medical abnormalities (e.g., vital signs),
Not obtaining a medical history and family history,
Indiscriminate screening without an organizing framework,
Missing a toxic psychosis by not screening for substances and medications,
Not asking their family or others about dietary supplements,
Premature diagnostic closure, and
Not revisiting or questioning the initial diagnostic impression of primary psychiatric disorder.Only after relevant and known causes of psychosis are excluded, a mental health clinician may make a psychiatric differential diagnosis using a persons family history, incorporating information from the person with psychosis, and information from family, friends, or significant others. Types of psychosis in psychiatric disorders may be established by formal rating scales.
Methamphetamine-induced psychosis is likely gated by genetic vulnerability, which can produce long-term changes in brain neurochemistry following repetitive use. Medication
Administration, or sometimes withdrawal, of a large number of medications may provoke psychotic symptoms. Drugs that can induce psychosis experimentally or in a significant proportion of people include stimulants, such as amphetamine and other sympathomimetics, dopamine agonists, ketamine, corticosteroids (often with mood changes in addition), and some anticonvulsants such as vigabatrin. Pathophysiology
Neuroimaging
The first brain image of an individual with psychosis was completed as far back as 1935 using a technique called pneumoencephalography (a painful and now obsolete procedure where cerebrospinal fluid is drained from around the brain and replaced with air to allow the structure of the brain to show up more clearly on an X-ray picture). Both first episode psychosis, and high risk status is associated with reductions in grey matter volume (GMV). First episode psychotic and high risk populations are associated with similar but distinct abnormalities in GMV. Reductions in the right middle temporal gyrus, right superior temporal gyrus (STG), right parahippocampus, right hippocampus, right middle frontal gyrus, and left anterior cingulate cortex (ACC) are observed in high risk populations. Reductions in first episode psychosis span a region from the right STG to the right insula, left insula, and cerebellum, and are more severe in the right ACC, right STG, insula and cerebellum.Another meta analysis reported bilateral reductions in insula, operculum, STG, medial frontal cortex, and ACC, but also reported increased GMV in the right lingual gyrus and left precentral gyrus.