This poem was written two days after the birth of Yeats's daughter Anne, who arrived in the world on on February 26, 1919. The Irish were fighting the English for independence, and Yeats was staying at the ancient (fifteenhth century) Thoor Ballylee Castle in Ireland, a tower castle that represented to Yeats a more stable period of history.
In the poem, Yeats sees his infant daughter as caught between two possible realities: the first is the storm that had been "howling" in Irish politics (not to mention idea of the "gracious" past being overturned by the recently-ended carnage of World War I). The second is the opposite reality: what he calls "ceremony" and "custom." These virtues are represented to him by the tower in which he is staying.
Yeats wishes that his daughter won't be too beautiful or intelligent but, instead, that she be gracious. He writes:
In courtesy I'd have her chiefly learned;
Hearts are not had as a gift but hearts are earned
In other words, in today's language, he would like her to have high emotional intelligence and good people skills. He wants her to avoid the "hate" he sees all around.
He wishes for her the safety and security that the ancient tower represents. He wants her to marry into tradition and find a stable way of life:
And may her bridegroom bring her to a house
Where all's accustomed, ceremonious
Yeats seeks safety in the past; his ideas for his daughter seem sexist by today's standards but are meant to represent a dream of stability in an insecure world.