As hundreds of thousands of federal workers fretted Friday about how they will pay bills amid the partial government shutdown, the missed paychecks turned out to be particularly cruel for nearly three dozen employees at one obscure government agency.

Their checks slipped right through their hands, or at least through their bank accounts.

Because of an apparent clerical error, a federal division that processes paychecks for a big chunk of the government workforce mistakenly paid about 30 employees at the Chemical Safety and Hazard Investigation Board. The District-based board investigates industrial chemical accidents, but nearly all of the board’s employees have been furloughed during the government shutdown.

The chemical safety board’s payroll is processed by the Interior Business Center, which handles payments for 240,000 employees at 42 agencies. On Friday morning, the center mistakenly paid the furloughed chemical safety board employees, as well as two other Interior Department employees, according to a senior department official.

Within hours, the Interior Business Center recognized the mistake. The leaders of the chemical safety board quickly sent out an urgent email asking employees not to spend the money.

“PLEASE DO NOT ACCESS THE FUNDS,” the email read. “We are working with IBC to determine how to remedy this situation and it is best if you don’t access the funds.”

An Interior Department official, who spoke on the condition of anonymity to discuss personnel matters, said a chemical safety board employee submitted an improper payroll code, triggering the error.

Furloughed federal employees, who do not work during the shutdown, are supposed to be assigned a payroll code of 105, the official said. Excepted employees — who work during the shutdown but may not be paid until it has been resolved — are supposed to be given a code of 107. Exempted employees, who work during the shutdown and expect to be paid, are coded 010, the official said.

“As best we’re told, the coder for the board was a new person who did not understand how to do the coding properly,” the official said.

On Friday, Interior Business Center officials spent the morning recouping the payments by freezing the deposits after they had been sent to banks.

“There are three banks that are involved, and we’ve called the banks to trace that money and work to pull it back,” said the official, adding that the department recalled payments to the two other Interior Department employees.

Despite the error, the official said the process of withholding paychecks to hundreds of thousands of federal workers largely functioned as planned.

Before 2002, the federal government had 26 payroll systems for federal employees. The systems were restricted by President George W. Bush, resulting in their being consolidated into four shared-service providers managed by the Pentagon, the General Services Administration, the Agriculture Department and the Interior Department.

Three years ago, the Interior Business Center became a source of ire for federal employees after it failed to pay 40,000 of them on time. The error forced the agency to contact banks to urge them not to punish federal workers who feared bounced checks and late mortgage payments — just the sort of angst the U.S. government workforce now faces.