A thyroid-stimulating hormone (TSH) test measures the amount of TSH in blood. TSH is produced by the pituitary gland, which is responsible for regulating the amount of hormones released by the thyroid. A TSH test is often performed to determine the underlying cause of abnormal thyroid hormone levels. It’s also used to screen for an underactive or overactive thyroid gland. The level of TSH in the blood, can determine how well the thyroid is working.