If a person's income is a mix of lawful and unlawful money, it is a doubtful matter and should be cleaned up. The Prophet ﷺ taught us to avoid doubtful matters, and the Quran forbids taking wealth unjustly (2:188). The unlawful part must be separated and left, and a person should work toward fully lawful earnings. Ask a scholar how to deal with money already received.
اموال يكديگر را به ناشايست مخوريد و آن را به رشوت به حاكمان مدهيد تا بدان سبب اموال گروهى ديگر را به ناحق بخوريد. و شما خود مىدانيد.
Hadith
Sahih al-Bukhari 52
Narrated An-Nu'man bin Bashir: I heard Allah's Messenger (ﷺ) saying, 'Both legal and illegal things are evident but in between them there are doubtful (suspicious) things and most of the people have no knowledge about them. So whoever saves himself from these suspicious things saves his religion and his honor. And whoever indulges in these suspicious things is like a shepherd who grazes (his animals) near the Hima (private pasture) of someone else and at any moment he is liable to get in it. (O people!) Beware! Every king has a Hima and the Hima of Allah on the earth is His illegal (forbidden) things. Beware! There is a piece of flesh in the body if it becomes good (reformed) the whole body becomes good but if it gets spoilt the whole body gets spoilt and that is the heart
Abu Huraira reported Allah's Messenger (ﷺ) as saying:O people, Allah is Good and He therefore, accepts only that which is good. And Allah commanded the believers as He commanded the Messengers by saying: "O Messengers, eat of the good things, and do good deeds; verily I am aware of what you do" (xxiii. 51). And He said: "O those who believe, eat of the good things that We gave you" (ii. 172). He then made a mention of a person who travels widely, his hair disheveled and covered with dust. He lifts his hand towards the sky (and thus makes the supplication): "O Lord, O Lord," whereas his diet is unlawful, his drink is unlawful, and his clothes are unlawful and his nourishment is unlawful. How can then his supplication be accepted?
This is general information, not a fatwa. For your own situation, ask a qualified scholar.
Questions about halal and haram
Is money from mixed sources halal?
If a person's income is a mix of lawful and unlawful money, it is a doubtful matter and should be cleaned up. The Prophet ﷺ taught us to avoid doubtful matters, and the Quran forbids taking wealth unjustly (2:188). The unlawful part must be separated and left, and a person should work toward fully lawful earnings. Ask a scholar how to deal with money already received.