In addition to the wise advice stated above (specifically for bass), there are capable DI's that are designed for both pass. & act input signals. I use an Aphex Bass Exciter which incorporates a DI output @ mic level and an act./pass. input selection switch which provides a max 12db loss of level in order to avoid signal overload. Hi & Lo freq'y blending ctls allows me to "flavor" my signal. It's also a pretty good unit when used in bass cabs/amplification giving a sorta' "parametric eq" dynamic to bass tonality.
Another all-around,basic and useful DI for both bass & git is the ProCo DB-1.
An economic and decent approach for DI apps.