The Oct. 11 fire that burned down a Kenner apartment complex and left dozens of residents homeless began inside a shed — packed with flammable painting supplies — that a tenant had built without permission in the patio area of one of the units, authorities said Wednesday.

An initial investigation of the blaze at 4100 Alabama Ave. also found that numerous cigarette butts had been discarded in the vicinity of the makeshift shed, leading officials to conclude that the cause was almost certainly accidental, Deputy Chief Brant Thompson, of the state Fire Marshal’s Office, said.

Neither Kenner officials nor the two-building complex’s owners, Swee-Eng and Elaine Huang, knew a shed housing paint thinners and similar supplies had been erected behind an apartment until after the fire, Thompson said.

Kenner Code Enforcement Department Director Aimee Vallot said city inspectors had been to the property many times while making their routine rounds. The owners had been cited for minor property code violations nine times since 1996, which isn’t an unusual number for a 20-unit complex, Vallot said.

But those inspections were limited by law to the exterior of the complex, Vallot said, meaning the city had no way of discovering the dangerous shed or ordering that it be taken down.

Vallot said she was awaiting a final report from the state Fire Marshal’s Office to determine whether any action can be taken against the tenant, whose name was not available Wednesday.

Once the fire started inside the shed and spread to the unit, there was little to prevent it from destroying the complex, Thompson and Vallot said.

The complex lacked firewalls in the units’ attics because it was built at a time when they were not required. As a result, Thompson said, the blaze was able to jump rapidly between units and then to the adjacent building before firefighters arrived.

“With old construction ... it’s not uncommon,” Thompson said of the lack of firewalls. “Our construction environment is much safer today.”

An exact construction date for the building wasn’t available Wednesday, but public records suggest it went up around the 1970s.

While no one was injured in the fire, as many as 36 people needed to stay overnight at a temporary shelter the Red Cross opened at a nearby gym until they could make new living arrangements.

Both Vallot and Thompson said it appeared the Huangs plan to demolish the complex rather than try to rehabilitate it. The Huangs had no comment on their plans.