Rather than being ironic, the argument can be made that the title "The Gift of the Magi" is metaphoric. For, in the conclusion of the story, O.Henry, intrudes as narrator,
The Magi, as you know, were wise men--....They invented the art of giving Christmas presents. Being wise, their gifts were no doubt wise ones....And here I have lamely related to you the uneventful chronicle of two foolish children in a flat who most unwisely sacrificed for each other the greatest treasures of their house. But in a last word to the wise of these days, let it be said that of all who give gifts these two were the wisest. Of all who give and receive gifts, such as they are wisest.
O. Henry clearly states overtly his theme that the "foolish" love of Della and Jim is really the truest love and overtly states also that Jim and Della are the magi and they are "the wisest." While the reader initially recognizes the Biblical allusion of the title, as he/she reads, the reader then realizes that the title is a metaphor for Jim and Della, ironically stated, perhaps, since the "foolish" children are "wise." Typical of his endings, O. Henry sets on end coventional ideas in "The Gift of the Magi."
The irony in the "Magi" is that the truth of love was inside of them all the time; they didn't have to look for it in a present, or inthe ritual of giving. The meaning is based on the irony in the bible story. The kings saw a star in the desert and followed it thinking it was a spiritual sign. For example, "the star which they had seen in the east, went before them, until it came and stood over where the child was"(Matthew: 2:9.)
A fact of astronomy is that the actual position of a star in the sky changes one degree everyday. Therefore, a fixed star could never, in actuality, have led them to Bethlehem.
Only a miracle could have occured(if you believe in miracles). This means that they were following a spiritual sign. Of course, they did find the infant in the stable.
The irony in their trip is that they had to look outside of themselves to discover love. It is the same irony as in the story because the couple's love was there all along;they didn't have to prove it my buying a gift for each other or by sacrificing their own best parts.
What is ironic in the title of this story is the fact that, at least arguably, the two protagonists of the story have not acted wisely. Therefore, it is ironic to call them "wise men."
In the story, the young couple, Jim and Delia Young, want to buy each other Christmas gifts, but can't really afford it.
Jim sells his beloved heirloom watch to buy Delia some beautiful combs for her hair, she sells her hair to buy a nice chain for his watch. So neither has anything after they've given their gifts.
I, however, don't think the title really is ironic, because they have truly given each other the greatest gifts of all -- proof that they truly love each other and are willing to make sacrifices for one another.