Kette was born in the small village of Prem near the Carniolan town of Ilirska Bistrica, in what was then part of the Austro-Hungarian Empire (now in Slovenia). His father was a teacher and a choirmaster; his mother died when he was four years old. In 1898, he enrolled in the State Secondary School in Ljubljana. In 1894, his maternal uncle, Janez Valenčič, who was paying for Kette's scholarship, withdrew his financial support because Kette published some satirical verses about the bishop of Ljubljana Jakob Missia in the student paper. Kette had to continue his studies in Novo Mesto, where he passed his high-school leaving exam in 1898. In Novo Mesto, he fell in love with the daughter of the district judge, Angela Smola, to whom he dedicated his most beautiful poems.
During his high school years, he became acquainted with the young writers Ivan Cankar, Oton Župančič, and Josip Murn, who were introducing modernist elements into Slovene literature.
After graduating from high school, Kette was drafted by the Austro-Hungarian Army and sent to Trieste. In Trieste, he fell sick with tuberculosis and returned to Ljubljana, where he settled in a small room in a flophouse on the banks of the Ljubljanica River (an abandoned sugar factory known as Cukrarna). He died there in 1899, at the age of 23. In the last weeks of his life, he was tended by his close friend Josip Murn, who died two years later in the same bed.
He is buried in the Žale cemetery in the Bežigrad district of Ljubljana.
Kette's poetry was mostly influenced by Slovene folk songs and by classic writers such as Goethe, Heine, and Prešeren. Through his friends, he became acquainted with French symbolist and decadentist poets, particularly Paul Verlaine and Maurice Maeterlinck, but rejected them. He chose an original approach instead, similar to neo-romantic trends in fin-de-siècle Europe.
His most famous works include the lyrical impressionist poem "Na trgu" (On the Square), and a cycle of eight poems entitled "Na Molu San Carlo" (On Saint Charles Pier), written in Trieste.
Kette is also known as an author of popular children's literature. He wrote about 25 stories and poems for children; the best known are "The Tale of the Dressmaker and the Little Scissors," "The Sultan and the Doggy," and "The Bee and the Bumblebee." His children's literature is remains popular and has been translated into German, Czech, Serbian, Croatian, Macedonian, and Hungarian.
Unlike his friend Josip Murn, Kette became an established poet already during his lifetime. His death was followed by semi-official mourning and several public figures, including the mayor of Ljubljana Ivan Hribar, attended Kette's funeral. His collected poems were published in 1900, edited by Anton Aškerc (then considered the most important author in Slovenian), who had previously rejected Kette's poetry. Aškerc's condescending and patronizing preface to the edition was strongly criticized by Ivan Cankar and Oton Župančič, leading to a public dispute in which the young Slovenian writers challenged the aesthetic standards of the older generations, represented by Aškerc. On the first anniversary of Kette's death, Ivan Cankar published an influential essay in his memory, which began with the words:
A year ago, Dragotin Kette passed away in Ljubljana and some newspapers reported that we had lost a very talented poet. Few realized that the young man that had died was the biggest talent we have had since Prešeren.
Kette had an important influence on future Slovenian writers, such as Alojz Gradnik, Srečko Kosovel, Miran Jarc, Ivan Minatti, Janez Menart, Kajetan Kovič, and Ciril Zlobec.