By Wilde in his spoken lecture on Personal Impressions of America at least as early as September 1883.
In a newspaper essay by Wilde:
The Philosophy of Dress, New-York Tribune, April 19th, 1885, 9 
 This essay remained unknown to modern scholarship until its rediscovery in 2012 by John Cooper, the author of this web site. [Not in Mason.]
Reused by Wilde in The Woman's World a magazine he edited:
‘Literary and Other Notes I’, By The Editor. The Woman's World. November 1887. pp 36-40:
"And, after all, what is a fashion? From the artistic point of view, it is usually a form of ugliness so intolerable that we have to alter it every six months."
As noted above, the quotation first appeared in print in Wilde's essay The Philosophy of Dress. That essay first appeared in book form in the First Edition of:
John Cooper, Oscar Wilde On Dress (CSM Press), 2013.
”Fashion rests upon folly. Art rests upon law. Fashion is ephemeral. Art is eternal. Indeed what is a fashion really? A fashion is merely a form of ugliness so absolutely unbearable that we have to alter it every six months! It is quite clear that were it beautiful and rational we would not alter anything that combined those two rare qualities. And wherever dress has been so, it has remained unchanged in law and principle for many hundred years."
‘The Philosophy of Dress’, New York Tribune, April 19th, 1885, 9. Excerpt.