Both are い-adjectives meaning "small".
From what I gather (though I'm not sure), chiisai is used mainly for specifying objects as 'small'; while komakai can have uses like: "minute differences", "trivial matters", "finer details".
Japanese Language Stack Exchange is a question and answer site for students, teachers, and linguists wanting to discuss the finer points of the Japanese language. It only takes a minute to sign up.
Sign up to join this community小さい = small (not to be big/wide etc.),
小さい部屋 → small room
It can also carry the nuance of:
(彼は)小さいです。 → He is small (size/age)
(彼は)まだ小さいです。→ He is still young. (まだ gives emphasis on the "small age")
小さい話 → A trivial or unimportant story
小さい声 → quiet voice; (quietly)
細かい = tiny, but also means: detailed;
When 細かい refers to an object, it is something smaller than 小さい,
Also 細かい can have a negative nuance: 金に細かい (stingy with money) -> very common expression
There are many differences, but a rule of thumb is that 小さい is about size while 細かい is about granularity. As such, 細かい tends to imply that you are talking about many/repeated small things (of the same kind).
小さい出費 (one small spending)
細かい出費 (small/tiny spendings here and there)
Adding to 悪戯猫さん's explanation: I've often heard the phrase 「細かいことまで聞いてすみません」 when you ask questions down to the smallest detail and you are worried you would annoy the listener with it.
Some additional detail, from the perspective of word derivations and related terms. 😄
Modern ちいさい comes from older ちひさし. This word appears in the 日本書紀【にほんしょき】 of 720, one of the oldest texts to include written Japanese. At that time, ちぴさし was likely pronounced as something like //tipisasi//.
Via that ancient //tipi// root, ちいさい is likely related to various other words:
Modern こまかい looks like it ultimately traces back to こま. こま itself is either from 子 or 小 (ko, "small; baby, child") + 馬 (uma, appearing in some compounds as ma, "horse"), or from 小 (ko, "small") + 間 (ma, "space between things").
Via that //koma// root, こまかい is likely related to various other words: