You can only use [conditional tags][1] after the `posts_selection` [action hook][2] has run. According to the codex article on [add_feed][3] it should be called with the `init` action, which runs before. Now I don't know when and how you run it, because you don't say so in the above example, but I'd assume you do it before `posts_selection` - that would explain your dilemma anyway. The following is both untested and just guesswork, since you don't really clarify the exact situation in which you want to use the above, but the following ought to work, unless it clashes with the feed actions, with which I have no experience: function feed_conditional() { if ( is_home() ) add_feed( 'home_feed', 'hf_output' ); else add_feed( 'regular_feed', 'rf_output' ); } add_action( 'wp_head', 'feed_conditional' ); // your feed output functions [1]: http://codex.wordpress.org/Conditional_Tags [2]: http://codex.wordpress.org/Plugin_API/Action_Reference#Actions_Run_During_a_Typical_Request [3]: http://codex.wordpress.org/Rewrite_API/add_feed