State Farm Mutual, the nation's biggest car insurer, made so much money during the first six months of the year that it will give back $45 million to its policyholders, the company said yesterday.

The dividends, to be paid in October, are the first in three years for State Farm which, like other major insurance companies, has reported small profits or even underwriting losses in recent years.

State Farm officials said the dividend is an alternative to cutting rates, because it is uncertain whether profits will hold up for the rest of the year.

State Farm's 15,000 customers in the District of Columbia will get dividends amounting to 6.5 per cent of their half-year premium, an average of $8.60. The money will be subtracted from the next premium due and refunded in cash to persons no longer insured by State Farm.

The dividend will be 5.8 per cent of the half-year premiums in Maryland, an average of $6.19, and will be 3.8 per cent in Virginia, averaging $3.40.

The dividends will amount to $3.9 million in the Washington area - $130,000 to 15,000 customers in the District, $1,610,000 to 473 Virginia policyholders and $2,180,000 to 352,000 in Maryland.

Nationally, the dividends range from 0.6 per cent in Kansas to 10.3 per cent in Alaska, depending on State Farm's profits in the state. State Farm customers in 31 states will get dividends, but there will be none in states where the company lost money.

State Farm reported profits of $192.3 million in the first half of this year, including $128.9 million in underwriting earnings.

Underwriting earnings mean the company collected more in premiums than it paid out in claims during the period. State Farm lost $33.9 million on underwriting in the first half of 1976.

Most major auto insurance companies have made only small profits or have lost money on underwriting in recent years, getting most of their earnings from investments.

State Farm spokesman Ronald Arnold called the sharp surge in profits for the first half of the year "an anomaly" and said the company's actuaries are at a loss to explain it completely.

The rate at which State Farm claims were filed declined slightly, from 28.4 per 100 insured cars to 28.0, he said. "That doesn't seem like much, but when you apply it to 15 million cars, it is," added Arnold.

The higher profits also reflect recent rate increases which are just now affecting the company's profits, the spokesman said. It takes a year after rates are raised for all the new revenue to be collected.

Company officials cautioned against expecting the trend to fewer accidents to continue or counting on insurance rates going down, or even stopping their increase.

Auto insurance rates could go down if the claims rate slows and the cost of repairs stabilizes, the State Farm officials said For the first half of the year, the average State Farm claim was $390, up from $375 the year before.

No other major auto insurers have announced dividends or rate reductions, but insurance officials indicated there are some signs of improved profits in the whole industry.

State Farm said the lower claims rate does not seem to correlate to the 55 miles per hour speed limit, safely equipment on cars or any other obvious factors.

The decline in claims was not universal, but occurred in 31 states, including Florida, which had been the worst state in the country for auto accidents. State Farm said it made a $16 million profit in Florida and is giving its policyholders there a 6 per cent dividend.

State Farm said its claim rate improved even though it wrote more than a million new policies during the first half of the year. Usually new customers have a worse accident record than previous policyholders.

State Farm's dividends will only partially offset rate increases it got last year in Virginia, Maryland and the District. State Farm got rate increase of 19 per cent in Maryland last March, 15.2 per cent in the District in September and 7.1 per cent in Virginia last December.

The rate increases were based on the company's experience in previous years, which gave no clue that claims might slow down, a State Farm official said.

In Georgia, State Farm will be paying a 0.6 per cent dividend at the same time it is seeking a 9.6 per cent rate boost.