Beginning July 1, the major credit bureaus—Equifax, Experian, and TransUnion—will limit the use of many tax liens and most civil court judgments in the data used to calculate credit scores because of complaints that the data is often wrong and unfairly hurts consumers. The bureaus also will limit the use of overdue medical bills and eliminate other credit report items such as unpaid parking tickets.

According to data broker LexisNexis, the new measures about tax liens and judgments will affect about 12 million Americans who currently have such information on their credit reports. Some of those people will see their FICO credit scores rise by as much as 40 points, although most will see more modest gains of 20 points or less.

The decision to restrict the use of civil judgments and tax liens in credit scores comes as the credit bureaus have fallen under pressure—from state attorneys general and the Consumer Financial Protection Bureau—to make credit reports more accurate and fair.

Maureen Mahoney, a policy analyst with Consumers Union, the policy and mobilization arm of Consumer Reports, says too few steps were being taken to ensure that judgments and tax liens were applied to the correct credit reports. Names got confused, addresses weren’t included, and Social Security numbers were omitted.

The result is that some credit reports were unfairly blemished, which can stop a qualified person from being approved for a mortgage, a credit card, and even a job.

Under the new standards, the major credit bureaus will include these public records only if they can be matched to a credit report with the consumer’s name, address, and date of birth or Social Security number—a standard that most public records do not meet. The information on those records will also need to be updated every 90 days to remain on the credit report.

Mahoney says that should help improve the accuracy of credit reports. She also advises that consumers check their credit reports next month to see whether such data has been removed, and if it hasn’t, contact the credit bureaus to find out why. If necessary, she says, you can also file a complaint with the Consumer Financial Protection Bureau.

To view your free credit report, download it at AnnualCreditReport.com