If you conduct or transact business in CA--that is, sell anything in CA, provide services in CA, etc.--then you have to register as a foreign entity. Living in CA, paying taxes on your income (as a state resident) in CA, etc. does not require you to register: only coducting business in a state does.