Yes. Vegetable oil can be substituted for butter in most cases.
General Rule for Substituting Oil for Butter in Baking:
1 cup Butter = 7/8 cup vegetable oil
But it is important to understand the purpose of butter in the recipe for which you want to replace. Here are the following cases where substituting butter completely with oil might make a difference to the end product.
Substituting Butter in Cakes
In cakes where a creaming of butter and sugar is involved in the initial stages, substituting oil equally will not provide as great a result as that with butter. This is because while creaming, you are essentially incorporating air. These air bubbles contribute to fluffy, spongy cakes. I would recommend instead to make a partial substitution for the butter in such cases.
Substituting Butter in Brownies
From my personal, I have made a successful 1:1 substitution in brownies.
Substituting Butter in Pies
Butter helps in providing a flaky texture to the pie crust which is something we associate our pies to be. Oil does not provide that texture. Instead you can try using Vegetable Shortening like I have done in my Apple Rosemary Pie
Substituting Butter in Cookies
Just as in the case of cakes, if you're cookie recipe asks for creaming butter and sugar, then equal substitution of oil would most probably result in denser (even greasy looking) cookies. In that case, the best substitute would be do about 1/3 rd of the butter and or replacing it with applesauce or banana.