Police said the 41-year-old suspect broke into the Kyoto Animation studio on Thursday morning and sprayed petrol before igniting it.
The suspect has been detained and was taken to hospital with injuries.
Japan's Prime Minister Shinzo Abe said the incident was "too appalling for words" and offered condolences.
It is one of Japan's worst mass casualty incidents since World War Two.
Kyoto Animation, known as KyoAni, produces films and graphic novels, and is well regarded by fans for the quality of its productions.