While the terms are sometimes used interchangeably, there are differences between editorial and opinion pieces.
Editorial -- a piece written by the editors or publishers of the publication.
Opinion -- sometimes written by editors or publishers, sometimes written by community members
Op-Eds -- typically written by experts on a given topic; not people working for the publication.
Letters to the Editor -- written by readers of the publication in response to news reported by that publication.
--Content adapted from Tulsa Community College
What Is Editorial Content in Journalism? -- New York Times Licensing
Opinion, news or editorial? Readers often can’t tell the difference. -- Poynter
How to Write an Effective Op-Ed -- Boston University