The answer is Yes. But there is a catch!
When voters cast their ballot – we vote President & VP together – it doesn’t matter if they are from the same state.
But when the Electoral College votes, they vote for each position separately. And only one of those positions can be from the state they represent.
So if the Pres & VP candidates on a ballot are both from Texas, the Texas Electors can only vote for one of them and have to give the other vote to someone else.
In 2000, Bush and Cheney were in fact lboth from Texas, but Cheney registered to vote in Wyoming so it wouldn’t become an issue. They ended up with 271 EC votes (270 are required to win). If Cheney had been a Texas registered voter, the Electors would have had to choose between Bush & Cheney. Texas has 32 EC votes so one of them would have received only 239 votes.
Learn more: https://history.house.gov/Institution/Electoral-College/Electoral-College/