From the Massachusetts Department of Revenue:
1st - Massachusetts Source Income That is Excluded
Massachusetts gross income excludes certain items of income derived from sources within Massachusetts: non-business related interest, dividends and gains from the sale or exchange of intangibles, and qualified pension income.
2nd - Massachusetts Source Income That is Included:
Massachusetts gross income includes items of income derived from sources within Massachusetts. This includes income:
- derived from or effectively connected with any trade of business, including any employment carried on by the taxpayer in Massachusetts, whether or not the nonresident is actively engaged in a trade or business or employment in Massachusetts in the year in which the income is received;
- from any lottery or wagering transaction in Massachusetts;
- from ownership of any interest in real or tangible personal property located in Massachusetts;
- from patents, copyrights and other similar intangibles connected to Massachusetts; and
- of all other types falling within the definition of Massachusetts source income.
3rd - Trade or business, Including Employment Carried on in Massachusetts:
A nonresident has a trade or business, including any employment carried on in Massachusetts if:
- the nonresident, directly or through agents or employees, maintains or operates or shares in maintaining or operating a desk, a room, an office, a shop, a store, a warehouse, a factory, or any other place in Massachusetts where the business affairs are systematically and regularly conducted; or
- the nonresident, directly or through agents or employees, is present for business in Massachusetts as either an employee, sole proprietor, or other self-employed individual.
A nonresident generally is not engaged in a trade or business, including any employment carried on in Massachusetts if the nonresident's presence for business in Massachusetts is casual, isolated and inconsequential. A nonresident's presence for business in Massachusetts will ordinarily be considered casual, isolated and inconsequential if it meets the requirements of the Ancillary Activity Test (AAT) and Examples.
When nonresidents earn or derive income from sources both within Massachusetts and elsewhere, and no exact determination can be made of the amount of Massachusetts source income, an apportionment of income must be made to determine that amount considered Massachusetts gross income.
4th - Apportionment of Income:
The three most common apportionment methods used to determine Massachusetts source income are as follows:
Gross income is multiplied by a:
- Employees Compensated on an Hourly, Daily, Weekly, or monthly Basis:
fraction, the numerator of which is the number of days spent working in Massachusetts and the denominator of which is the total working days;
- Employees Compensated on a Mileage Basis:
fraction, the numerator of which is the total mileage traveled in Massachusetts and the denominator of which is the employee's total mileage upon which the employer computes total wages;
fraction, the numerator of which is the amount of sales made within Massachusetts and the denominator of which is the amount of sales made everywhere.
So if you go to Massachusetts to work, you have to pay the tax. If you collect a share of the profit or revenue from Massachusetts, you have to pay tax on that. If you work from Oregon and are paid for that work, then you don't pay Massachusetts tax on that. If anything, your company might have to pay Oregon taxes on revenue you generate (you are their agent or employee in Oregon).
Does the answer change depending on whether the income is reported at 1099 or W-2?
This shouldn't matter legally. It's possible that it would be easier to see that the work was done in Oregon in one or the other. I.e. it doesn't make any legal difference but may make a practical difference.
All this assumes that you are purely an employee or contractor and not an owner. If you are an owner, you have to pay taxes on any income from your Massachusetts business. Note that this applies to things like copyrights and real estate as well as the business.
This also assumes that you are doing your work in Oregon. If you live in Oregon and travel to Massachusetts to work, you pay taxes on your Massachusetts income in Massachusetts.